diff options
author | Nico Weber <thakis@chromium.org> | 2021-09-06 17:40:15 -0400 |
---|---|---|
committer | Linus Groh <mail@linusgroh.de> | 2021-09-07 20:29:22 +0100 |
commit | 1ed1a57707abe30ab3a1c43d72b087bcb2af0af7 (patch) | |
tree | 9167c8b1f582794216e2323709aadd0b669409fb /Toolchain | |
parent | 82cb885966c7399725610c821f94ccb4caed7f1a (diff) | |
download | serenity-1ed1a57707abe30ab3a1c43d72b087bcb2af0af7.zip |
Meta: Make `serenity.sh rebuild-toolchain aarch64 clang` work
Diffstat (limited to 'Toolchain')
-rwxr-xr-x | Toolchain/BuildClang.sh | 2 | ||||
-rw-r--r-- | Toolchain/Patches/llvm.patch | 9 |
2 files changed, 10 insertions, 1 deletions
diff --git a/Toolchain/BuildClang.sh b/Toolchain/BuildClang.sh index 59020cf24d..37d17a6ea4 100755 --- a/Toolchain/BuildClang.sh +++ b/Toolchain/BuildClang.sh @@ -253,7 +253,7 @@ pushd "$DIR/Build/clang/$ARCH" -DCMAKE_BUILD_TYPE="MinSizeRel" \ -DCMAKE_INSTALL_PREFIX="$PREFIX" \ -DLLVM_DEFAULT_TARGET_TRIPLE="$LLVM_TARGET" \ - -DLLVM_TARGETS_TO_BUILD=X86 \ + '-DLLVM_TARGETS_TO_BUILD=X86;AArch64' \ -DLLVM_ENABLE_BINDINGS=OFF \ -DLLVM_ENABLE_PER_TARGET_RUNTIME_DIR=OFF \ -DLLVM_ENABLE_PROJECTS="clang;lld" \ diff --git a/Toolchain/Patches/llvm.patch b/Toolchain/Patches/llvm.patch index 6fc16786ab..31a039300d 100644 --- a/Toolchain/Patches/llvm.patch +++ b/Toolchain/Patches/llvm.patch @@ -2,6 +2,15 @@ diff --git a/clang/lib/Basic/Targets.cpp b/clang/lib/Basic/Targets.cpp index 90a67d03b..ad21af415 100644 --- a/clang/lib/Basic/Targets.cpp +++ b/clang/lib/Basic/Targets.cpp +@@ -148,6 +148,8 @@ TargetInfo *AllocateTarget(const llvm::Triple &Triple, + return new NetBSDTargetInfo<AArch64leTargetInfo>(Triple, Opts); + case llvm::Triple::OpenBSD: + return new OpenBSDTargetInfo<AArch64leTargetInfo>(Triple, Opts); ++ case llvm::Triple::Serenity: ++ return new SerenityTargetInfo<AArch64leTargetInfo>(Triple, Opts); + case llvm::Triple::Win32: + switch (Triple.getEnvironment()) { + case llvm::Triple::GNU: @@ -527,6 +527,8 @@ TargetInfo *AllocateTarget(const llvm::Triple &Triple, return new MCUX86_32TargetInfo(Triple, Opts); case llvm::Triple::Hurd: |