clang  10.0.0svn
Linux.cpp File Reference
#include "Linux.h"
#include "Arch/ARM.h"
#include "Arch/Mips.h"
#include "Arch/PPC.h"
#include "Arch/RISCV.h"
#include "CommonArgs.h"
#include "clang/Config/config.h"
#include "clang/Driver/Distro.h"
#include "clang/Driver/Driver.h"
#include "clang/Driver/Options.h"
#include "clang/Driver/SanitizerArgs.h"
#include "llvm/Option/ArgList.h"
#include "llvm/ProfileData/InstrProf.h"
#include "llvm/Support/Path.h"
#include "llvm/Support/ScopedPrinter.h"
#include "llvm/Support/VirtualFileSystem.h"
#include <system_error>
Include dependency graph for Linux.cpp:

Go to the source code of this file.


static std::string getMultiarchTriple (const Driver &D, const llvm::Triple &TargetTriple, StringRef SysRoot)
 Get our best guess at the multiarch triple for a target. More...
static StringRef getOSLibDir (const llvm::Triple &Triple, const ArgList &Args)
static void addMultilibsFilePaths (const Driver &D, const MultilibSet &Multilibs, const Multilib &Multilib, StringRef InstallPath, ToolChain::path_list &Paths)
static std::string DetectLibcxxIncludePath (llvm::vfs::FileSystem &vfs, StringRef base)

Function Documentation

◆ addMultilibsFilePaths()

static void addMultilibsFilePaths ( const Driver D,
const MultilibSet Multilibs,
const Multilib Multilib,
StringRef  InstallPath,
ToolChain::path_list Paths 

Definition at line 211 of file Linux.cpp.

◆ DetectLibcxxIncludePath()

static std::string DetectLibcxxIncludePath ( llvm::vfs::FileSystem &  vfs,
StringRef  base 

Definition at line 868 of file Linux.cpp.

References clang::interp::LE().

Referenced by clang::driver::toolchains::Linux::addLibCxxIncludePaths().

◆ getMultiarchTriple()

static std::string getMultiarchTriple ( const Driver D,
const llvm::Triple &  TargetTriple,
StringRef  SysRoot 

Get our best guess at the multiarch triple for a target.

Debian-based systems are starting to use a multiarch setup where they use a target-triple directory in the library and header search paths. Unfortunately, this triple does not align with the vanilla target triple, so we provide a rough mapping here.

Definition at line 40 of file Linux.cpp.

References clang::driver::Driver::getVFS().

Referenced by clang::driver::toolchains::Linux::addLibStdCxxIncludePaths().

◆ getOSLibDir()

static StringRef getOSLibDir ( const llvm::Triple &  Triple,
const ArgList &  Args