diff options
author | dim <dim@FreeBSD.org> | 2011-02-20 13:06:31 +0000 |
---|---|---|
committer | dim <dim@FreeBSD.org> | 2011-02-20 13:06:31 +0000 |
commit | 39fcc9a984e2820e4ea0fa2ac4abd17d9f3a31df (patch) | |
tree | a9243275843fbeaa590afc07ee888e006b8d54ea /include/clang/Driver/ToolChain.h | |
parent | 69b4eca4a4255ba43baa5c1d9bbdec3ec17f479e (diff) | |
download | FreeBSD-src-39fcc9a984e2820e4ea0fa2ac4abd17d9f3a31df.zip FreeBSD-src-39fcc9a984e2820e4ea0fa2ac4abd17d9f3a31df.tar.gz |
Vendor import of clang trunk r126079:
http://llvm.org/svn/llvm-project/cfe/trunk@126079
Diffstat (limited to 'include/clang/Driver/ToolChain.h')
-rw-r--r-- | include/clang/Driver/ToolChain.h | 39 |
1 files changed, 38 insertions, 1 deletions
diff --git a/include/clang/Driver/ToolChain.h b/include/clang/Driver/ToolChain.h index 55be4ee..f0012bd 100644 --- a/include/clang/Driver/ToolChain.h +++ b/include/clang/Driver/ToolChain.h @@ -10,10 +10,11 @@ #ifndef CLANG_DRIVER_TOOLCHAIN_H_ #define CLANG_DRIVER_TOOLCHAIN_H_ +#include "clang/Driver/Util.h" #include "clang/Driver/Types.h" #include "llvm/ADT/SmallVector.h" #include "llvm/ADT/Triple.h" -#include "llvm/System/Path.h" +#include "llvm/Support/Path.h" #include <string> namespace clang { @@ -32,6 +33,11 @@ class ToolChain { public: typedef llvm::SmallVector<std::string, 4> path_list; + enum CXXStdlibType { + CST_Libcxx, + CST_Libstdcxx + }; + private: const HostInfo &Host; const llvm::Triple Triple; @@ -92,6 +98,10 @@ public: // Platform defaults information + /// HasNativeLTOLinker - Check whether the linker and related tools have + /// native LLVM support. + virtual bool HasNativeLLVMSupport() const; + /// LookupTypeForExtension - Return the default language type to use for the /// given extension. virtual types::ID LookupTypeForExtension(const char *Ext) const; @@ -103,6 +113,14 @@ public: /// by default. virtual bool IsIntegratedAssemblerDefault() const { return false; } + /// IsStrictAliasingDefault - Does this tool chain use -fstrict-aliasing by + /// default. + virtual bool IsStrictAliasingDefault() const { return true; } + + /// IsObjCDefaultSynthPropertiesDefault - Does this tool chain enable + /// -fobjc-default-synthesize-properties by default. + virtual bool IsObjCDefaultSynthPropertiesDefault() const { return false; } + /// IsObjCNonFragileABIDefault - Does this tool chain set /// -fobjc-nonfragile-abi by default. virtual bool IsObjCNonFragileABIDefault() const { return false; } @@ -153,6 +171,25 @@ public: /// sets the deployment target) determines the version in the triple passed to /// Clang. virtual std::string ComputeEffectiveClangTriple(const ArgList &Args) const; + + // GetCXXStdlibType - Determine the C++ standard library type to use with the + // given compilation arguments. + virtual CXXStdlibType GetCXXStdlibType(const ArgList &Args) const; + + /// AddClangCXXStdlibIncludeArgs - Add the clang -cc1 level arguments to set + /// the include paths to use for the given C++ standard library type. + virtual void AddClangCXXStdlibIncludeArgs(const ArgList &Args, + ArgStringList &CmdArgs) const; + + /// AddCXXStdlibLibArgs - Add the system specific linker arguments to use + /// for the given C++ standard library type. + virtual void AddCXXStdlibLibArgs(const ArgList &Args, + ArgStringList &CmdArgs) const; + + /// AddCCKextLibArgs - Add the system specific linker arguments to use + /// for kernel extensions (Darwin-specific). + virtual void AddCCKextLibArgs(const ArgList &Args, + ArgStringList &CmdArgs) const; }; } // end namespace driver |