diff options
author | Campbell Barton <ideasman42@gmail.com> | 2011-10-21 08:23:26 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2011-10-21 08:23:26 +0400 |
commit | d37760bc34340386a679dbd06b81b6cb8b95ceca (patch) | |
tree | 5e150a942fdee8902ab36dee03dacf89cf9e66aa /build_files/scons/config/darwin-config.py | |
parent | 78a8f8a4b12b9088eccf444fff49cd27f8bb3e4d (diff) |
cleanup scons build flags, many duplicates because because of confusion between CFLAGS/CPPFLAGS/CCFLAGS/CXXFLAGS, devs would set multiple to be on the safe side.
- defines go in CPPFLAGS
- C & C++ flags go in CCFLAGS
- CFLAGS / CXXFLAGS are C OR C++ only.
also commented intended ghost unicode/ascii usage.
Diffstat (limited to 'build_files/scons/config/darwin-config.py')
-rw-r--r-- | build_files/scons/config/darwin-config.py | 26 |
1 files changed, 12 insertions, 14 deletions
diff --git a/build_files/scons/config/darwin-config.py b/build_files/scons/config/darwin-config.py index 0c132041d82..deb3d01febd 100644 --- a/build_files/scons/config/darwin-config.py +++ b/build_files/scons/config/darwin-config.py @@ -306,11 +306,11 @@ if MACOSX_ARCHITECTURE == 'x86_64' or MACOSX_ARCHITECTURE == 'ppc64': else: ARCH_FLAGS = ['-m32'] -CFLAGS = ['-pipe','-funsigned-char']+ARCH_FLAGS +CFLAGS = [] +CXXFLAGS = [] +CCFLAGS = ['-pipe','-funsigned-char'] -CPPFLAGS = []+ARCH_FLAGS -CCFLAGS = ['-pipe','-funsigned-char']+ARCH_FLAGS -CXXFLAGS = ['-pipe','-funsigned-char']+ARCH_FLAGS +CPPFLAGS = list(ARCH_FLAGS) if WITH_GHOST_COCOA: PLATFORM_LINKFLAGS = ['-fexceptions','-framework','CoreServices','-framework','Foundation','-framework','IOKit','-framework','AppKit','-framework','Cocoa','-framework','Carbon','-framework','AudioUnit','-framework','AudioToolbox','-framework','CoreAudio','-framework','OpenAL']+ARCH_FLAGS @@ -336,9 +336,8 @@ else: # some flags shuffling for different OS versions if MAC_MIN_VERS == '10.3': - CFLAGS = ['-fuse-cxa-atexit']+CFLAGS - CXXFLAGS = ['-fuse-cxa-atexit']+CXXFLAGS - PLATFORM_LINKFLAGS = ['-fuse-cxa-atexit']+PLATFORM_LINKFLAGS + CCFLAGS = ['-fuse-cxa-atexit'] + CFLAGS + PLATFORM_LINKFLAGS = ['-fuse-cxa-atexit'] + PLATFORM_LINKFLAGS LLIBS.append('crt3.o') if USE_SDK: @@ -349,19 +348,18 @@ if USE_SDK: #Intel Macs are CoreDuo and Up if MACOSX_ARCHITECTURE == 'i386' or MACOSX_ARCHITECTURE == 'x86_64': - REL_CFLAGS = ['-DNDEBUG', '-O2','-ftree-vectorize','-msse','-msse2','-msse3','-mfpmath=sse'] + REL_CFLAGS = [] + REL_CXXFLAGS = [] REL_CCFLAGS = ['-DNDEBUG', '-O2','-ftree-vectorize','-msse','-msse2','-msse3','-mfpmath=sse'] else: - CFLAGS = CFLAGS+['-fno-strict-aliasing'] - CCFLAGS = CCFLAGS+['-fno-strict-aliasing'] - CXXFLAGS = CXXFLAGS+['-fno-strict-aliasing'] - REL_CFLAGS = ['-DNDEBUG', '-O2'] + CCFLAGS += ['-fno-strict-aliasing'] + REL_CFLAGS = [] + REL_CXXFLAGS = [] REL_CCFLAGS = ['-DNDEBUG', '-O2'] # Intel 64bit Macs are Core2Duo and up if MACOSX_ARCHITECTURE == 'x86_64': - REL_CFLAGS = REL_CFLAGS+['-march=core2','-mssse3','-with-tune=core2','-enable-threads'] - REL_CCFLAGS = REL_CCFLAGS+['-march=core2','-mssse3','-with-tune=core2','-enable-threads'] + REL_CCFLAGS += ['-march=core2','-mssse3','-with-tune=core2','-enable-threads'] CC_WARN = ['-Wall'] C_WARN = ['-Wno-char-subscripts', '-Wpointer-arith', '-Wcast-align', '-Wdeclaration-after-statement', '-Wno-unknown-pragmas', '-Wstrict-prototypes'] |