#!/usr/bin/python import os import csbuild import sys from csbuild.toolchain_msvc import VisualStudioPackage # Force the local copy of csbuild to be used rather than the installed copy. sys.path.insert(0, "../../../") csbuild.Toolchain("gcc", "ios").Compiler().SetCppStandard("c++11") csbuild.Toolchain("gcc", "ios").SetCppStandardLibrary("libc++") csbuild.Toolchain("msvc").SetMsvcVersion(VisualStudioPackage.Vs2012) csbuild.DisablePrecompile() csbuild.DisableChunkedBuild() OUT_DIR = "out/{project.activeToolchainName}-{project.outputArchitecture}/{project.targetName}" INT_DIR = "obj/{project.activeToolchainName}-{project.outputArchitecture}/{project.targetName}/{project.name}" csbuild.SetOutputDirectory(OUT_DIR) csbuild.SetIntermediateDirectory(INT_DIR) csbuild.AddIncludeDirectories("src") csbuild.AddLibraryDirectories(OUT_DIR) @csbuild.project("sharedLibrary", "src/sharedLibrary") def sharedLibrary(): csbuild.SetOutput("sharedLibrary", csbuild.ProjectType.SharedLibrary) @csbuild.project("staticLibrary", "src/staticLibrary") def staticLibrary(): csbuild.SetOutput("staticLibrary", csbuild.ProjectType.StaticLibrary) @csbuild.project("loadableModule", "src/loadableModule") def loadableModule(): csbuild.SetOutput("loadableModule", csbuild.ProjectType.LoadableModule) @csbuild.project("mainApp", "src/mainApp", ["sharedLibrary", "staticLibrary"]) def mainApp(): csbuild.AddLibraries("sharedLibrary", "staticLibrary") csbuild.SetOutput("mainApp", csbuild.ProjectType.Application)
# | Change | User | Description | Committed | |
---|---|---|---|---|---|
#4 | 14799 | brandon_m_bare |
-- Removed some things from the HelloLibraries that don't exist anymore. -- Added code to the msvc toolchain that will automatically detect the best version of Visual Studio that a user has installed if they don't specify a version in their makefile. #review-14796 @ShadauxCat |
||
#3 | 13943 | brandon_m_bare |
-- Reorganized how plist generation works so it's now completely encapsulated within the plist generator plugin. -- Cleaned up the app bundle generation process for the gcc_darwin toolchain. -- Added functions in gcc_darwin to get the proper base paths inside an app bundle (overrode those functions for the ios toolchain since the paths need to be different there). -- Added a utility function to completely remove a directory tree. Like shutil.rmtree(), but this one actually works. -- Fixed Objective-C/C++ files getting chunked when they shouldn't have been. -- Added dSYM generation for osx and ios (only occurs when an app bundle is also generated). -- Added the default active development directory and toolchain directory to the gcc_darwin and ios toochains. -- Added code in gcc_darwin to copy shared libraries and loadable modules into app bundles. |
||
#2 | 12345 | brandon_m_bare |
-- Cleaned up the gcc_darwin toolchain so that the SDK path and version are automatically retrieved only once in the entire execution of a make script. -- Similarly updated the ios toolchain so it's SDK paths and version are automatically retrieved. -- Cleaned up the sys path modification in the HelloLibraries makefile. #review-12337 @ShadauxCat |
||
#1 | 11833 | brandon_m_bare |
UnitTest: -- Added the OSX unit test, HelloLibraries. NOTE: This unit test should work for other PC-based platforms, but it's specifically OSX to show off the difference loadable modules and shared libraries (which are technically the same thing, but Apple makes a clear distinction between the two). |