diff options
author | Alon Zakai <alonzakai@gmail.com> | 2012-01-02 12:44:49 -0800 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2012-01-02 12:44:49 -0800 |
commit | aa449f08f0dfd1fb3581ab0c40b7633f718be7e3 (patch) | |
tree | 207a4e88b32640cafe0ca47011e661b4000ff0fc /tools | |
parent | 1190bdc0c0a81a4ee711ce6d4eb46e275308d1d4 (diff) |
use -idirafter instead of -I for our system dirs, to allow overriding
Diffstat (limited to 'tools')
-rw-r--r-- | tools/shared.py | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/tools/shared.py b/tools/shared.py index 2b3ac951..12490cdf 100644 --- a/tools/shared.py +++ b/tools/shared.py @@ -147,14 +147,16 @@ COMPILER_OPTS = COMPILER_OPTS + ['-m32', '-U__i386__', '-U__x86_64__', '-U__i386 USE_EMSDK = not os.environ.get('EMMAKEN_NO_SDK') if USE_EMSDK: - EMSDK_OPTS = [ '-nostdinc', - '-I' + path_from_root('system', 'include'), - '-I' + path_from_root('system', 'include', 'bsd'), # posix stuff - '-I' + path_from_root('system', 'include', 'libc'), - '-I' + path_from_root('system', 'include', 'libcxx'), - '-I' + path_from_root('system', 'include', 'gfx'), - '-I' + path_from_root('system', 'include', 'net'), - '-I' + path_from_root('system', 'include', 'SDL'), + # Disable system C and C++ include directories, and add our own (using -idirafter so they are last, like system dirs, which + # allows projects to override them) + EMSDK_OPTS = [ '-nostdinc', '-nostdinc++', + '-idirafter' + path_from_root('system', 'include'), + '-idirafter' + path_from_root('system', 'include', 'bsd'), # posix stuff + '-idirafter' + path_from_root('system', 'include', 'libc'), + '-idirafter' + path_from_root('system', 'include', 'libcxx'), + '-idirafter' + path_from_root('system', 'include', 'gfx'), + '-idirafter' + path_from_root('system', 'include', 'net'), + '-idirafter' + path_from_root('system', 'include', 'SDL'), ] + [ '-U__APPLE__' ] |