diff options
author | Nathan Letwory <nathan@letworyinteractive.com> | 2006-02-24 00:08:40 +0300 |
---|---|---|
committer | Nathan Letwory <nathan@letworyinteractive.com> | 2006-02-24 00:08:40 +0300 |
commit | 2f8f1b8cdfa40d4af7fef506e1a0eab3c7462277 (patch) | |
tree | 3cd83ba2ca79565c9dfad9cc8be7e40956e29a6b | |
parent | ecdfa5374aa929dd2c78f306ae1ffa9dee1040e9 (diff) |
==SCons==
+ When giving CC and CXX on the command-line you can specify what compiler
to use:
scons CC=gcc-3.3 CXX=g++-3.3
-rw-r--r-- | SConstruct | 7 | ||||
-rwxr-xr-x | tools/btools.py | 4 |
2 files changed, 9 insertions, 2 deletions
diff --git a/SConstruct b/SConstruct index 8d0c0356b9d..70931073ad7 100644 --- a/SConstruct +++ b/SConstruct @@ -108,6 +108,13 @@ if not env: print "Could not create a build environment" Exit() +cc = B.arguments.get('CC', None) +cxx = B.arguments.get('CXX', None) +if cc: + env['CC'] = cc +if cxx: + env['CXX'] = cxx + if env['CC'] in ['cl', 'cl.exe'] and sys.platform=='win32': platform = 'win32-vc' elif env['CC'] in ['gcc'] and sys.platform=='win32': diff --git a/tools/btools.py b/tools/btools.py index afa21f2d28f..ba14712c201 100755 --- a/tools/btools.py +++ b/tools/btools.py @@ -37,14 +37,14 @@ def validate_arguments(args, bc): 'WITH_BF_FTGL', 'BF_FTGL', 'BF_FTGL_INC', 'BF_FTGL_LIB', 'WITH_BF_FFMPEG', 'WITH_BF_PLAYER', - 'CFLAGS', 'CCFLAGS', 'CPPFLAGS', + 'CFLAGS', 'CCFLAGS', 'CPPFLAGS', 'REL_CFLAGS', 'REL_CCFLAGS', 'C_WARN', 'CC_WARN', 'LLIBS', 'PLATFORM_LINKFLAGS', 'BF_PROFILE_FLAGS' ] arg_list = ['BF_DEBUG', 'BF_QUIET', 'BF_CROSS', 'BF_UPDATE', 'BF_INSTALLDIR', 'BF_TOOLSET', 'BF_BINNAME', 'BF_BUILDDIR', 'BF_FANCY', 'BF_QUICK', 'BF_PROFILE', 'BF_DEBUG', - 'BF_PRIORITYLIST', 'BF_BUILDINFO' + 'BF_PRIORITYLIST', 'BF_BUILDINFO','CC', 'CXX' ] all_list = opts_list + arg_list |