diff options
| author | Daniel Dunbar <daniel@zuster.org> | 2008-08-11 21:35:06 +0000 |
|---|---|---|
| committer | Daniel Dunbar <daniel@zuster.org> | 2008-08-11 21:35:06 +0000 |
| commit | 3ad53483fb706bce1f50c363a38a8dfa242e1ace (patch) | |
| tree | fca092c8062c98360f0bbb7bf2c6d5812dbf90eb /clang/Driver/clang.cpp | |
| parent | ec9e1a60ad3dd54f4e362247783cba2d72b36f2b (diff) | |
| download | bcm5719-llvm-3ad53483fb706bce1f50c363a38a8dfa242e1ace.tar.gz bcm5719-llvm-3ad53483fb706bce1f50c363a38a8dfa242e1ace.zip | |
Add LangOptions::NeXTRuntime.
- Wired to -fnext-runtime and -fgnu-runtime options.
- Defaults to GNU, no autoselection for NeXT.
Emit NeXT OBJC_IMAGE_INFO marker.
llvm-svn: 54651
Diffstat (limited to 'clang/Driver/clang.cpp')
| -rw-r--r-- | clang/Driver/clang.cpp | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/clang/Driver/clang.cpp b/clang/Driver/clang.cpp index c55aa17eb2b..089faf12555 100644 --- a/clang/Driver/clang.cpp +++ b/clang/Driver/clang.cpp @@ -373,6 +373,14 @@ static llvm::cl::opt<bool> Exceptions("fexceptions", llvm::cl::desc("Enable support for exception handling.")); +static llvm::cl::opt<bool> +GNURuntime("fgnu-runtime", + llvm::cl::desc("Generate output compatible with the standard GNU Objective-C runtime.")); + +static llvm::cl::opt<bool> +NeXTRuntime("fnext-runtime", + llvm::cl::desc("Generate output compatible with the NeXT runtime.")); + // FIXME: add: // -ansi // -trigraphs @@ -439,6 +447,15 @@ static void InitializeLanguageStandard(LangOptions &Options, LangKind LK) { Options.WritableStrings = WritableStrings; Options.LaxVectorConversions = LaxVectorConversions; Options.Exceptions = Exceptions; + + if (NeXTRuntime) { + Options.NeXTRuntime = 1; + } else if (GNURuntime) { + Options.NeXTRuntime = 0; + } else { + // FIXME: Should autoselect based on platform. + Options.NeXTRuntime = 0; + } } static llvm::cl::opt<bool> |

