diff options
author | Daniel Dunbar <daniel@zuster.org> | 2009-01-29 06:12:22 +0000 |
---|---|---|
committer | Daniel Dunbar <daniel@zuster.org> | 2009-01-29 06:12:22 +0000 |
commit | 2d43e3bbd27f536d300f2295a9651847631ee867 (patch) | |
tree | 3c6d3a7d7377d157339da59e7547ad207657e73e /tools/ccc/ccclib/Tools.py | |
parent | 161ddee636c58f5227286c8d4d81266df84b4ad4 (diff) |
ccc: Honor -ccc-clang for generic GCC toolchain.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@63277 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/ccc/ccclib/Tools.py')
-rw-r--r-- | tools/ccc/ccclib/Tools.py | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/tools/ccc/ccclib/Tools.py b/tools/ccc/ccclib/Tools.py index 62720624cb..a24255c652 100644 --- a/tools/ccc/ccclib/Tools.py +++ b/tools/ccc/ccclib/Tools.py @@ -247,12 +247,14 @@ class Clang_CompileTool(Tool): not arglist.getLastArg(arglist.parser.staticOption) and not arglist.getLastArg(arglist.parser.m_dynamicNoPicOption))) - archName = arglist.getValue(arch) - if (archName == 'x86_64' or - picEnabled): - cmd_args.append('--relocation-model=pic') - elif not arglist.getLastArg(arglist.parser.m_dynamicNoPicOption): - cmd_args.append('--relocation-model=static') + # FIXME: This needs to tie into a platform hook. + if arch: + archName = arglist.getValue(arch) + if (archName == 'x86_64' or + picEnabled): + cmd_args.append('--relocation-model=pic') + elif not arglist.getLastArg(arglist.parser.m_dynamicNoPicOption): + cmd_args.append('--relocation-model=static') if arglist.getLastArg(arglist.parser.f_timeReportOption): cmd_args.append('--time-passes') |