[clang] [Driver] Implement ToolChain on Haiku (PR #66038)
Fangrui Song via cfe-commits
cfe-commits at lists.llvm.org
Tue Sep 19 21:35:13 PDT 2023
================
@@ -2426,6 +2432,31 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
using std::begin;
using std::end;
+ if (TargetTriple.isOSHaiku()) {
+ static const char *const HaikuLibDirs[] = {"/lib"};
+ static const char *const HaikuAArch64Triples[] = {"aarch64-unknown-haiku"};
+ static const char *const HaikuRISCV64Triples[] = {"riscv64-unknown-haiku"};
+ static const char *const HaikuX86Triples[] = {"i586-unknown-haiku"};
+ static const char *const HaikuX86_64Triples[] = {"x86_64-unknown-haiku"};
+ LibDirs.append(begin(HaikuLibDirs), end(HaikuLibDirs));
+ switch (TargetTriple.getArch()) {
+ case llvm::Triple::aarch64:
+ TripleAliases.append(begin(HaikuAArch64Triples), end(HaikuAArch64Triples));
----------------
MaskRay wrote:
If `--target=` is correct, we don't need any `TripleAliases` ?
https://github.com/llvm/llvm-project/pull/66038
More information about the cfe-commits
mailing list