usvfs = Project("usvfs") def usvfs_environment(): env = config['__environment'].copy() env['BOOST_PATH'] = boost_folder return env for (project32, dependencies) in [("boost", ["boost_prepare"]), ("GTest", []), ("usvfs", [])]: if config['architecture'] == 'x86_64': unimake32 = \ build.Run_With_Output(r'"{0}" unimake.py --set architecture="x86" -b "build" -p "progress" -i "install" -d "{1}" {2} "{3}"'.format(sys.executable, config['__build_base_path'],' -s ' + ' -s '.join(config['__Arguments'].set) if config['__Arguments'].set is not None else "", project32), name="unimake_x86_{}".format(project32), environment=config['__Default_environment'], working_directory=os.path.join(os.getcwd())) for dep in dependencies: unimake32.depend(dep) Project(project32 + "_32").depend(unimake32) else: Project(project32 + "_32").dummy().depend(project32) usvfs \ .depend(msbuild.MSBuild("usvfs.sln", vs_target, os.path.join(build_path, "usvfs", "vsbuild"), "{}".format("x64" if config['architecture'] == 'x86_64' else "x86"), None, None, None, usvfs_environment()) .depend("boost" + suffix) .depend("GTest" + suffix) .depend(github.Source('247321453', "usvfs", usvfs_version)))
] if config.get('optimize', False): cmake_parameters.append( "-DOPTIMIZE_LINK_FLAGS=\"/LTCG /INCREMENTAL:NO /OPT:REF /OPT:ICF\"") usvfs = Project("usvfs") suffix_32 = "" if config['architecture'] == 'x86_64' else "_32" for (project32, dependencies) in [("boost", ["boost_prepare"]), ("GTest", []), ("usvfs", [])]: if config['architecture'] == 'x86_64': unimake32 = \ build.Run_With_Output( r'"{0}" unimake.py -d "{1}" --set architecture="x86" -b "build" -p "progress" -i "install" {2}'.format( sys.executable, config['__build_base_path'], project32), name="unimake_x86_{}".format(project32), environment=config['__Default_environment'], working_directory=os.path.join(os.getcwd())) for dep in dependencies: unimake32.depend(dep) Project(project32 + "_32").depend(unimake32) else: Project(project32 + "_32").dummy().depend(project32) # usvfs build: vs_target = "Clean;Build" if config['rebuild'] else "Build" usvfs_build = \ msbuild.MSBuild("usvfs.sln", vs_target, os.path.join(config["paths"]["build"], "usvfs", "vsbuild"), "x64" if config['architecture'] == 'x86_64' else "x86") usvfs_build.depend(
"-DPROJ_ARCH={}".format("x86" if config['architecture'] == 'x86' else "x64") ]).install() # TODO Not sure why this is required, will look into it at a later stage once we get the rest to build .depend( github.Source(config['Main_Author'], "usvfs", "master").set_destination("usvfs")).depend( "AsmJit").depend("Udis86").depend("GTest").depend( "fmtlib").depend("spdlog").depend("boost")) if config['architecture'] == 'x86_64': usvfs_32 = Project("usvfs_32") usvfs_32.depend( build.Run_With_Output( r'"{0}" unimake.py -d "{1}" --set architecture="x86" -b "build_32" -p "progress_32" -i "install_32" usvfs' .format(sys.executable, config['__build_base_path']), name="Building usvfs 32bit Dll", environment=config['__Default_environment'], working_directory=os.path.join(os.getcwd()))) else: usvfs_32 = Project("usvfs_32") usvfs_32.depend(dummy.Success("usvfs_32")) for author, git_path, path, branch, dependencies, Build in [ (config['Main_Author'], "modorganizer-game_features", "game_features", "master", [], False), (config['Main_Author'], "modorganizer-archive", "archive", "master", ["7zip", "Qt5"], True), (config['Main_Author'], "modorganizer-uibase", "uibase", "QT5.7", ["Qt5", "boost"], True), (config['Main_Author'], "modorganizer-lootcli", "lootcli", "master", ["LootApi", "boost"], True),