clang  8.0.0svn
Linux.h
Go to the documentation of this file.
1 //===--- Linux.h - Linux ToolChain Implementations --------------*- C++ -*-===//
2 //
3 // The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 
10 #ifndef LLVM_CLANG_LIB_DRIVER_TOOLCHAINS_LINUX_H
11 #define LLVM_CLANG_LIB_DRIVER_TOOLCHAINS_LINUX_H
12 
13 #include "Gnu.h"
14 #include "clang/Driver/ToolChain.h"
15 
16 namespace clang {
17 namespace driver {
18 namespace toolchains {
19 
20 class LLVM_LIBRARY_VISIBILITY Linux : public Generic_ELF {
21 public:
22  Linux(const Driver &D, const llvm::Triple &Triple,
23  const llvm::opt::ArgList &Args);
24 
25  bool HasNativeLLVMSupport() const override;
26 
27  void
28  AddClangSystemIncludeArgs(const llvm::opt::ArgList &DriverArgs,
29  llvm::opt::ArgStringList &CC1Args) const override;
30  void addLibCxxIncludePaths(
31  const llvm::opt::ArgList &DriverArgs,
32  llvm::opt::ArgStringList &CC1Args) const override;
33  void addLibStdCxxIncludePaths(
34  const llvm::opt::ArgList &DriverArgs,
35  llvm::opt::ArgStringList &CC1Args) const override;
36  void AddCudaIncludeArgs(const llvm::opt::ArgList &DriverArgs,
37  llvm::opt::ArgStringList &CC1Args) const override;
38  void AddIAMCUIncludeArgs(const llvm::opt::ArgList &DriverArgs,
39  llvm::opt::ArgStringList &CC1Args) const override;
40  bool isPIEDefault() const override;
41  bool IsMathErrnoDefault() const override;
42  SanitizerMask getSupportedSanitizers() const override;
43  void addProfileRTLibs(const llvm::opt::ArgList &Args,
44  llvm::opt::ArgStringList &CmdArgs) const override;
45  virtual std::string computeSysRoot() const;
46 
47  virtual std::string getDynamicLinker(const llvm::opt::ArgList &Args) const;
48 
49  std::vector<std::string> ExtraOpts;
50 
51 protected:
52  Tool *buildAssembler() const override;
53  Tool *buildLinker() const override;
54 };
55 
56 } // end namespace toolchains
57 } // end namespace driver
58 } // end namespace clang
59 
60 #endif // LLVM_CLANG_LIB_DRIVER_TOOLCHAINS_LINUX_H
Driver - Encapsulate logic for constructing compilation processes from a set of gcc-driver-like comma...
Definition: Driver.h:58
Dataflow Directional Tag Classes.
Tool - Information on a specific compilation tool.
Definition: Tool.h:34
uint64_t SanitizerMask
Definition: Sanitizers.h:26
std::vector< std::string > ExtraOpts
Definition: Linux.h:49