class Multilib

Declaration

class Multilib { /* full declaration omitted */ };

Description

This corresponds to a single GCC Multilib, or a segment of one controlled by a command line flag

Declared at: clang/include/clang/Driver/Multilib.h:28

Member Variables

private std::string GCCSuffix
private std::string OSSuffix
private std::string IncludeSuffix
private clang::driver::Multilib::flags_list Flags
private int Priority

Method Overview

  • public Multilib(llvm::StringRef GCCSuffix = {}, llvm::StringRef OSSuffix = {}, llvm::StringRef IncludeSuffix = {}, int Priority = 0)
  • public void dump() const
  • public clang::driver::Multilib & flag(llvm::StringRef F)
  • public const clang::driver::Multilib::flags_list & flags() const
  • public clang::driver::Multilib::flags_list & flags()
  • public const std::string & gccSuffix() const
  • public clang::driver::Multilib & gccSuffix(llvm::StringRef S)
  • public const std::string & includeSuffix() const
  • public clang::driver::Multilib & includeSuffix(llvm::StringRef S)
  • public bool isDefault() const
  • public bool isValid() const
  • public const std::string & osSuffix() const
  • public clang::driver::Multilib & osSuffix(llvm::StringRef S)
  • public void print(llvm::raw_ostream & OS) const
  • public int priority() const

Methods

Multilib(llvm::StringRef GCCSuffix = {},
         llvm::StringRef OSSuffix = {},
         llvm::StringRef IncludeSuffix = {},
         int Priority = 0)

Declared at: clang/include/clang/Driver/Multilib.h:40

Parameters

llvm::StringRef GCCSuffix = {}
llvm::StringRef OSSuffix = {}
llvm::StringRef IncludeSuffix = {}
int Priority = 0

void dump() const

Declared at: clang/include/clang/Driver/Multilib.h:98

clang::driver::Multilib& flag(llvm::StringRef F)

Description

Add a flag to the flags list\p Flag must be a flag accepted by the driver with its leading '-' removed, and replaced with either: '-' which contraindicates using this multilib with that flag or: '+' which promotes using this multilib in the presence of that flag otherwise '-print-multi-lib' will not emit them correctly.

Declared at: clang/include/clang/Driver/Multilib.h:92

Parameters

llvm::StringRef F

const clang::driver::Multilib::flags_list& flags()
    const

Description

Get the flags that indicate or contraindicate this multilib's use All elements begin with either '+' or '-'

Declared at: clang/include/clang/Driver/Multilib.h:78

clang::driver::Multilib::flags_list& flags()

Declared at: clang/include/clang/Driver/Multilib.h:79

const std::string& gccSuffix() const

Description

Get the detected GCC installation path suffix for the multi-arch target variant. Always starts with a '/', unless empty

Declared at: clang/include/clang/Driver/Multilib.h:45

clang::driver::Multilib& gccSuffix(
    llvm::StringRef S)

Description

Set the GCC installation path suffix.

Declared at: clang/include/clang/Driver/Multilib.h:52

Parameters

llvm::StringRef S

const std::string& includeSuffix() const

Description

Get the include directory suffix. Always starts with a '/', unless empty

Declared at: clang/include/clang/Driver/Multilib.h:67

clang::driver::Multilib& includeSuffix(
    llvm::StringRef S)

Description

Set the include directory suffix

Declared at: clang/include/clang/Driver/Multilib.h:74

Parameters

llvm::StringRef S

bool isDefault() const

Description

Check whether the default is selected

Declared at: clang/include/clang/Driver/Multilib.h:106

bool isValid() const

Description

Check whether any of the 'against' flags contradict the 'for' flags.

Declared at: clang/include/clang/Driver/Multilib.h:103

const std::string& osSuffix() const

Description

Get the detected os path suffix for the multi-arch target variant. Always starts with a '/', unless empty

Declared at: clang/include/clang/Driver/Multilib.h:56

clang::driver::Multilib& osSuffix(
    llvm::StringRef S)

Description

Set the os path suffix.

Declared at: clang/include/clang/Driver/Multilib.h:63

Parameters

llvm::StringRef S

void print(llvm::raw_ostream& OS) const

Description

print summary of the Multilib

Declared at: clang/include/clang/Driver/Multilib.h:100

Parameters

llvm::raw_ostream& OS

int priority() const

Description

Returns the multilib priority. When more than one multilib matches flags, the one with the highest priority is selected, with 0 being the default.

Declared at: clang/include/clang/Driver/Multilib.h:83