OLD | NEW |
---|---|
1 #!/usr/bin/python | 1 #!/usr/bin/python |
2 # Copyright (c) 2012 The Native Client Authors. All rights reserved. | 2 # Copyright (c) 2012 The Native Client Authors. All rights reserved. |
3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
5 | 5 |
6 import re | 6 import re |
7 import subprocess | 7 import subprocess |
8 | 8 |
9 from driver_tools import AddHostBinarySearchPath, DefaultOutputName, \ | 9 from driver_tools import AddHostBinarySearchPath, DefaultOutputName, \ |
10 DefaultPCHOutputName, DriverChain, GetArch, ParseArgs, ParseTriple, \ | 10 DefaultPCHOutputName, DriverChain, GetArch, ParseArgs, ParseTriple, \ |
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
65 'FRONTEND_TRIPLE' : 'le32-unknown-nacl', | 65 'FRONTEND_TRIPLE' : 'le32-unknown-nacl', |
66 | 66 |
67 'OPT_LEVEL' : '', # Default for most tools is 0, but we need to know | 67 'OPT_LEVEL' : '', # Default for most tools is 0, but we need to know |
68 # if it's explicitly set or not when the driver | 68 # if it's explicitly set or not when the driver |
69 # is only used for linking + translating. | 69 # is only used for linking + translating. |
70 'CC_FLAGS' : '-O${#OPT_LEVEL ? ${OPT_LEVEL} : 0} ' + | 70 'CC_FLAGS' : '-O${#OPT_LEVEL ? ${OPT_LEVEL} : 0} ' + |
71 '-fno-vectorize -fno-slp-vectorize ' + | 71 '-fno-vectorize -fno-slp-vectorize ' + |
72 '-fno-common ${PTHREAD ? -pthread} ' + | 72 '-fno-common ${PTHREAD ? -pthread} ' + |
73 '-nostdinc ${BIAS_%BIAS%} ' + | 73 '-nostdinc ${BIAS_%BIAS%} ' + |
74 '-fno-gnu-inline-asm ' + | 74 '-fno-gnu-inline-asm ' + |
75 '-target ${FRONTEND_TRIPLE}', | 75 '-target ${FRONTEND_TRIPLE} ' + |
76 '${IS_CXX ? -fexceptions}', | |
Derek Schuff
2016/03/08 21:24:15
This should be overridable using -fno-exceptions.
Petr Hosek
2016/03/08 21:33:22
We capture all '-f.*' flags and append them to CC_
Derek Schuff
2016/03/08 21:34:51
Ah yeah, i forgot about that. Do we have a test fo
| |
76 | 77 |
77 | 78 |
78 'ISYSTEM' : '${ISYSTEM_USER} ${STDINC ? ${ISYSTEM_BUILTIN}}', | 79 'ISYSTEM' : '${ISYSTEM_USER} ${STDINC ? ${ISYSTEM_BUILTIN}}', |
79 | 80 |
80 'ISYSTEM_USER' : '', # System include directories specified by | 81 'ISYSTEM_USER' : '', # System include directories specified by |
81 # using the -isystem flag. | 82 # using the -isystem flag. |
82 | 83 |
83 'ISYSTEM_BUILTIN': | 84 'ISYSTEM_BUILTIN': |
84 '${BASE_USR}/usr/include ' + | 85 '${BASE_USR}/usr/include ' + |
85 '${ISYSTEM_CLANG} ' + | 86 '${ISYSTEM_CLANG} ' + |
(...skipping 700 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
786 -g Generate complete debug information. | 787 -g Generate complete debug information. |
787 -gline-tables-only Generate debug line-information only | 788 -gline-tables-only Generate debug line-information only |
788 (allowing for stack traces). | 789 (allowing for stack traces). |
789 -flimit-debug-info Generate limited debug information. | 790 -flimit-debug-info Generate limited debug information. |
790 -save-temps Keep intermediate compilation results. | 791 -save-temps Keep intermediate compilation results. |
791 -v Verbose output / show commands. | 792 -v Verbose output / show commands. |
792 -h | --help Show this help. | 793 -h | --help Show this help. |
793 --help-full Show underlying clang driver's help message | 794 --help-full Show underlying clang driver's help message |
794 (warning: not all options supported). | 795 (warning: not all options supported). |
795 """ % (tool) | 796 """ % (tool) |
OLD | NEW |