aboutsummaryrefslogtreecommitdiffstats
path: root/main
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2015-06-30 09:32:45 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2015-06-30 09:34:02 +0000
commit4f3b691340594aaa7cb30ef55b892fcddec3933c (patch)
tree8432ad60e3d5af92b3d8a7aea7cd908ecb8715a6 /main
parentafec5955e0b9ea2c857c078be2ac676698589c66 (diff)
downloadaports-4f3b691340594aaa7cb30ef55b892fcddec3933c.tar.bz2
aports-4f3b691340594aaa7cb30ef55b892fcddec3933c.tar.xz
main/llvm: various arm fixes
Diffstat (limited to 'main')
-rw-r--r--main/llvm/APKBUILD20
-rw-r--r--main/llvm/clang-0006-musl-alpine-triple.patch181
-rw-r--r--main/llvm/clang-0007-musl-dynamic-linker-paths.patch4
-rw-r--r--main/llvm/llvm-0002-musl-triple.patch10
4 files changed, 201 insertions, 14 deletions
diff --git a/main/llvm/APKBUILD b/main/llvm/APKBUILD
index f083601eff..cb2c49d01a 100644
--- a/main/llvm/APKBUILD
+++ b/main/llvm/APKBUILD
@@ -2,7 +2,7 @@
# Maintainer: Travis Tilley <ttilley@gmail.com>
pkgname=llvm
pkgver=3.6.1
-pkgrel=5
+pkgrel=6
use_svn="false"
pkgdesc="low level virtual machine compiler system"
arch="all"
@@ -334,7 +334,7 @@ libs() {
}
md5sums="0947294a8c83c8d7f857dfc16204c4eb llvm-0001-fix-shared-build.patch
-40af0cae32b49689db4ba3bb6ff4677f llvm-0002-musl-triple.patch
+dacc40624cf09fa98de27016bebb1432 llvm-0002-musl-triple.patch
056178d87918d531f531b1b765a59e7c llvm-0003-musl-hacks.patch
346081b2f0825ca7f491155c4b3ca0ea compiler-rt-0001-musl-no-dlvsym.patch
eb3797555357896a92f74bf1bacfbdc2 compiler-rt-0002-musl-no-sanitizers.patch
@@ -344,8 +344,8 @@ eab0123372fa909817ed21cfcffdbe16 clang-0001-fix-stdint.h.patch
93ffbede80bc857c8ae6bed5ff016a52 clang-0003-add-alpine-linux-distro.patch
231fad6dc619ef6a54567c14082bf7af clang-0004-alpine-use-z-relro.patch
2967fea7ed0624d99808bc091be1bab4 clang-0005-alpine-hash-style-gnu.patch
-2848c592e5388069b7f4785085193078 clang-0006-musl-alpine-triple.patch
-e24a82edcd6caa5e405ff67a45d6befc clang-0007-musl-dynamic-linker-paths.patch
+1ae0e80cfd31a42b299a65ba67e244ef clang-0006-musl-alpine-triple.patch
+f69714b175a5a888f77d68e2ebf76167 clang-0007-musl-dynamic-linker-paths.patch
6bc4b7047042f9afec452a97c35c2cd5 clang-0008-alpine-PIE-by-default.patch
0ae0c5939c27750c52b39158fbc7a7a9 clang-0009-pass-host-triple-to-compiler-rt.patch
26831612243302f3ef964f355bf8c409 clang-0010-alpine-use-z-now.patch
@@ -356,7 +356,7 @@ ebf9e97be405ae126e134d3a357cd58a llvm-3.6.1.src.tar.xz
6f204b1feb324b1672ac907b32d927c0 compiler-rt-3.6.1.src.tar.xz
be80b9c2b6d5071c71bb47d79402b9da polly-3.6.1.src.tar.xz"
sha256sums="4f75c2a76cf4c439d65c8e67511cd91c895edf8ccf003a5f94ffa07c29456296 llvm-0001-fix-shared-build.patch
-e9e533b3e285a8dbabc8145526128f74dd67db0fdbab219169fa7c7a733c4b2a llvm-0002-musl-triple.patch
+98d92c6cb305faff141b1b5a7cfa18656bd80aa478e7a45984f27e60a80bfdd9 llvm-0002-musl-triple.patch
c6892c843b38c9a852367e5d76ffc29c21bdfd522adbc4c4e3e3c890a513c0db llvm-0003-musl-hacks.patch
94f5626b4729afb39ad00a6cac4f8d44e3ee6f3d87362268bcd2c0ec637edc22 compiler-rt-0001-musl-no-dlvsym.patch
7dd2d22c61892eb651809649606fb3722520a5d12f8d88c2e96be977d0f8b71a compiler-rt-0002-musl-no-sanitizers.patch
@@ -366,8 +366,8 @@ c6892c843b38c9a852367e5d76ffc29c21bdfd522adbc4c4e3e3c890a513c0db llvm-0003-musl
78449c4f7c9fdfaccef3b68039c69e7e041fb34862d39c803d7e6fac17f659aa clang-0003-add-alpine-linux-distro.patch
501ab6e3fb99c9ffb82329475051a633797bf824c0dea437843266f190c062a0 clang-0004-alpine-use-z-relro.patch
1c4dbd1d474bf08de5979d6f4399aeba29de9ba8950aa0688d081d82e552d7d3 clang-0005-alpine-hash-style-gnu.patch
-a7c3ab756cae110887dad315b8458212830949442a491618253c79eba754b546 clang-0006-musl-alpine-triple.patch
-c7612168defefcb35cc8c988ff8b519aa983f07a62fd3b2c67f7d468459ca48a clang-0007-musl-dynamic-linker-paths.patch
+b62205ddb4b76470ba433c69ecb20d1be41963d1f826b8a6937cc024d8159268 clang-0006-musl-alpine-triple.patch
+44667890d5fa1816ca6cb33e63b49c5e9cfcb8265cdae513b2d0bd0916726766 clang-0007-musl-dynamic-linker-paths.patch
39c275490e3360d50fe339406992616fad0fa9127204c9b93578ee2403ae850c clang-0008-alpine-PIE-by-default.patch
ec0c2014d455040499f599dc3d690fb92e54baf6058605be5f25c2c845629cfe clang-0009-pass-host-triple-to-compiler-rt.patch
a34aca360fa52231b6c8663ee8b1103492f1c2600a08cc670616ce97d14e0ba9 clang-0010-alpine-use-z-now.patch
@@ -378,7 +378,7 @@ f4ee70d870d550a9147ac6a548ce7daf7d9e6897348bf411f43c572966fb92b6 clang-tools-ex
fcbf610c77be6047f11ca10c4725610417beba832565115a9e2fcfe2897b649f compiler-rt-3.6.1.src.tar.xz
d085f97bcbb4e47b51ed60ba9a55b3fee394193e7e48ab5c5b0035e6fc80a7eb polly-3.6.1.src.tar.xz"
sha512sums="b3c0e0f74680e9b2d02f1c923a191ef5eb913be84105e4d63aae6a88b1dac758467cecad3430496a7945cebdc73ec5ee1f643dc5dc7b336fee920e3c8b6d54d2 llvm-0001-fix-shared-build.patch
-0029c8ced95f7e48b466aa5e87cb8002928face0d4db888f7f922781e8dd2bf5737206dcdec58f5989572e487fd76b2ec5883ef5551539f3ebc14c8e76ac2cce llvm-0002-musl-triple.patch
+49203df74402b2e080fafb99a4df54d1822dbd3e4e018c44f2b41c95fcfa01b14c8c505405fd1c8909eac5effd36c60decdc771b4db9a16faf5f980af75c7551 llvm-0002-musl-triple.patch
df8959d43af48054bc35e4125f98e5dab1e1b5beaf7b67e95791caf144efec06764bd31a9eb5efc2179932591de8b862ebf89592d131e47070c89f19412979b7 llvm-0003-musl-hacks.patch
f1e6d17f4cc618b6a1edba64bda652f210d3c839bd8d2d4eff81af0895176062dab1e8fa963d0fe2403311863aee083d257bdb57ad9b44e23a958286a0d2e12b compiler-rt-0001-musl-no-dlvsym.patch
45f64cd5863238b7f7ad2f4a3733455e17eb3ab3121ba3404404f312beb91bb4d109c7c3278f77fc78730086e70cfe6532e159efef30e34af0132ca44a965220 compiler-rt-0002-musl-no-sanitizers.patch
@@ -388,8 +388,8 @@ effed16bed6160c1629c72960424afed87f8c1c1290bf4eccd43da5a1fcb5b350242c01fcc1cc735
0b8108c96948a1704275a93f3b872572fe2c61a0cd3e7f4caf63c0ca262cc079e2424b70f41d20f4a9aebe30333e39e3c594b4240fd41f7bd9a6682e751a23d9 clang-0003-add-alpine-linux-distro.patch
ac72ea29d6f889f2b54915b97d56bc388e849da2f524b872241053fa6bb9dde4eb6b1333813070e3671115121da34c22ff1e87aa19ce82a393166143b30c7de4 clang-0004-alpine-use-z-relro.patch
0594cc85b6cf0be66e747eb7ba6af5aff401d65b4072f3da4a3e531795965f72df5a3850c7abbbe4e1fde3dc6ad583ecfc4a77429531bae02143b5ca36bed37e clang-0005-alpine-hash-style-gnu.patch
-e00a05f6a599b4686d6759c844f8283360a95bc6d1f171d4ab56ba7e17e017bc244f302ba2a4191a3e006bb8bc3b8d235de3624d423357fe30a3595d20bb9371 clang-0006-musl-alpine-triple.patch
-c4365cbf9645e7aacbef2392cd7418c055a45e178e4ad956dfe45eafc90ab1db70ff620dfeeec11a4fab550ec557385f2d75f68adc0830ce74b5ece7077a3baf clang-0007-musl-dynamic-linker-paths.patch
+0c87ff437bebc9dda188a710a6c32a6e7288692ff862556bb53f5e61b0ef6aa6bba74b9a9302808df6bfe1afaa41489203f45779c627c09e46ebffd1627eff3f clang-0006-musl-alpine-triple.patch
+d23c9fb922312229d333091122ca65d94a4595af651657d8cca5a57c5804642897947702567c213027b02c98204cac9b92fee4a3e9e514bd7c539902e84462f4 clang-0007-musl-dynamic-linker-paths.patch
2a217800aefbce07017b793a8c91e174dac20546343de47749b4b07b4905db9a55411ef45e482b8df93cb4dbbdf25415202c3257be36ae095a6f2de11935f80b clang-0008-alpine-PIE-by-default.patch
7628c1b12febb27d0a9ecb846205edec61044fbb963ba5e588863652bccbb05d1436febf8840ff4b47dfb326689bb142464be59a18b17bd5d30aa03bb7e76a9f clang-0009-pass-host-triple-to-compiler-rt.patch
1bec07a11885b4e1b692a1df1ca2de8075016619b4086d9114553386e4de5956fbc7da5e234075f08eb635df8c01ebf51c9e2fc33aa483f02050eddbe66e38d2 clang-0010-alpine-use-z-now.patch
diff --git a/main/llvm/clang-0006-musl-alpine-triple.patch b/main/llvm/clang-0006-musl-alpine-triple.patch
index 96a748f742..8d8842fdd4 100644
--- a/main/llvm/clang-0006-musl-alpine-triple.patch
+++ b/main/llvm/clang-0006-musl-alpine-triple.patch
@@ -8,8 +8,8 @@ index 6007a98..44e929f 100644
static const char *const ARMHFTriples[] = { "arm-linux-gnueabihf",
- "armv7hl-redhat-linux-gnueabi" };
+ "armv7hl-redhat-linux-gnueabi",
-+ "armv6-alpine-linux-musleabihf",
-+ "armv7-alpine-linux-musleabihf"};
++ "armv6-alpine-linux-muslgnueabihf",
++ "armv7-alpine-linux-muslgnueabihf"};
static const char *const ARMebLibDirs[] = { "/lib" };
static const char *const ARMebTriples[] = { "armeb-linux-gnueabi",
"armeb-linux-androideabi" };
@@ -34,5 +34,182 @@ index 6007a98..44e929f 100644
};
static const char *const MIPSLibDirs[] = { "/lib" };
+--- a/lib/Basic/Targets.cpp
++++ b/lib/Basic/Targets.cpp
+@@ -3933,6 +3933,8 @@
+ case llvm::Triple::Android:
+ case llvm::Triple::GNUEABI:
+ case llvm::Triple::GNUEABIHF:
++ case llvm::Triple::MuslEABI:
++ case llvm::Triple::MuslEABIHF:
+ setABI("aapcs-linux");
+ break;
+ case llvm::Triple::EABIHF:
+--- a/lib/CodeGen/TargetInfo.cpp
++++ b/lib/CodeGen/TargetInfo.cpp
+@@ -4344,6 +4344,8 @@
+ case llvm::Triple::EABIHF:
+ case llvm::Triple::GNUEABI:
+ case llvm::Triple::GNUEABIHF:
++ case llvm::Triple::MuslEABI:
++ case llvm::Triple::MuslEABIHF:
+ return true;
+ default:
+ return false;
+@@ -4354,6 +4356,7 @@
+ switch (getTarget().getTriple().getEnvironment()) {
+ case llvm::Triple::EABIHF:
+ case llvm::Triple::GNUEABIHF:
++ case llvm::Triple::MuslEABIHF:
+ return true;
+ default:
+ return false;
+@@ -7107,7 +7110,8 @@
+ Kind = ARMABIInfo::APCS;
+ else if (CodeGenOpts.FloatABI == "hard" ||
+ (CodeGenOpts.FloatABI != "soft" &&
+- Triple.getEnvironment() == llvm::Triple::GNUEABIHF))
++ (Triple.getEnvironment() == llvm::Triple::GNUEABIHF ||
++ Triple.getEnvironment() == llvm::Triple::MuslEABIHF)))
+ Kind = ARMABIInfo::AAPCS_VFP;
+
+ switch (Triple.getOS()) {
+--- a/lib/Driver/ToolChains.cpp
++++ b/lib/Driver/ToolChains.cpp
+@@ -1393,7 +1393,8 @@
+ case llvm::Triple::arm:
+ case llvm::Triple::thumb:
+ LibDirs.append(begin(ARMLibDirs), end(ARMLibDirs));
+- if (TargetTriple.getEnvironment() == llvm::Triple::GNUEABIHF) {
++ if (TargetTriple.getEnvironment() == llvm::Triple::GNUEABIHF ||
++ TargetTriple.getEnvironment() == llvm::Triple::MuslEABIHF) {
+ TripleAliases.append(begin(ARMHFTriples), end(ARMHFTriples));
+ } else {
+ TripleAliases.append(begin(ARMTriples), end(ARMTriples));
+@@ -1402,7 +1403,8 @@
+ case llvm::Triple::armeb:
+ case llvm::Triple::thumbeb:
+ LibDirs.append(begin(ARMebLibDirs), end(ARMebLibDirs));
+- if (TargetTriple.getEnvironment() == llvm::Triple::GNUEABIHF) {
++ if (TargetTriple.getEnvironment() == llvm::Triple::GNUEABIHF ||
++ TargetTriple.getEnvironment() == llvm::Triple::MuslEABIHF) {
+ TripleAliases.append(begin(ARMebHFTriples), end(ARMebHFTriples));
+ } else {
+ TripleAliases.append(begin(ARMebTriples), end(ARMebTriples));
+@@ -2502,6 +2504,8 @@
+ switch (getTriple().getEnvironment()) {
+ case llvm::Triple::GNUEABIHF:
+ case llvm::Triple::GNUEABI:
++ case llvm::Triple::MuslEABIHF:
++ case llvm::Triple::MuslEABI:
+ case llvm::Triple::EABI:
+ return false;
+
+@@ -2541,10 +2545,12 @@
+ switch (Triple.getEnvironment()) {
+ case llvm::Triple::EABI:
+ case llvm::Triple::GNUEABI:
++ case llvm::Triple::MuslEABI:
+ getFilePaths().push_back("=/usr/lib/eabi");
+ break;
+ case llvm::Triple::EABIHF:
+ case llvm::Triple::GNUEABIHF:
++ case llvm::Triple::MuslEABIHF:
+ getFilePaths().push_back("=/usr/lib/eabihf");
+ break;
+ default:
+@@ -2815,7 +2821,8 @@
+ // regardless of what the actual target triple is.
+ case llvm::Triple::arm:
+ case llvm::Triple::thumb:
+- if (TargetTriple.getEnvironment() == llvm::Triple::GNUEABIHF) {
++ if (TargetTriple.getEnvironment() == llvm::Triple::GNUEABIHF ||
++ TargetTriple.getEnvironment() == llvm::Triple::MuslEABIHF) {
+ if (llvm::sys::fs::exists(SysRoot + "/lib/arm-linux-gnueabihf"))
+ return "arm-linux-gnueabihf";
+ } else {
+@@ -2825,7 +2832,8 @@
+ return TargetTriple.str();
+ case llvm::Triple::armeb:
+ case llvm::Triple::thumbeb:
+- if (TargetTriple.getEnvironment() == llvm::Triple::GNUEABIHF) {
++ if (TargetTriple.getEnvironment() == llvm::Triple::GNUEABIHF ||
++ TargetTriple.getEnvironment() == llvm::Triple::MuslEABIHF) {
+ if (llvm::sys::fs::exists(SysRoot + "/lib/armeb-linux-gnueabihf"))
+ return "armeb-linux-gnueabihf";
+ } else {
+@@ -3246,7 +3254,8 @@
+ getTriple().getArch() == llvm::Triple::aarch64_be) {
+ MultiarchIncludeDirs = AArch64MultiarchIncludeDirs;
+ } else if (getTriple().getArch() == llvm::Triple::arm) {
+- if (getTriple().getEnvironment() == llvm::Triple::GNUEABIHF)
++ if (getTriple().getEnvironment() == llvm::Triple::GNUEABIHF ||
++ getTriple().getEnvironment() == llvm::Triple::MuslEABIHF)
+ MultiarchIncludeDirs = ARMHFMultiarchIncludeDirs;
+ else
+ MultiarchIncludeDirs = ARMMultiarchIncludeDirs;
+--- a/lib/Driver/Tools.cpp
++++ b/lib/Driver/Tools.cpp
+@@ -656,6 +656,7 @@
+ case llvm::Triple::FreeBSD:
+ switch(Triple.getEnvironment()) {
+ case llvm::Triple::GNUEABIHF:
++ case llvm::Triple::MuslEABIHF:
+ FloatABI = "hard";
+ break;
+ default:
+@@ -668,6 +669,7 @@
+ default:
+ switch(Triple.getEnvironment()) {
+ case llvm::Triple::GNUEABIHF:
++ case llvm::Triple::MuslEABIHF:
+ FloatABI = "hard";
+ break;
+ case llvm::Triple::GNUEABI:
+@@ -789,6 +791,8 @@
+ case llvm::Triple::Android:
+ case llvm::Triple::GNUEABI:
+ case llvm::Triple::GNUEABIHF:
++ case llvm::Triple::MuslEABI:
++ case llvm::Triple::MuslEABIHF:
+ ABIName = "aapcs-linux";
+ break;
+ case llvm::Triple::EABIHF:
+@@ -6561,6 +6565,8 @@
+ switch(getToolChain().getTriple().getEnvironment()) {
+ case llvm::Triple::GNUEABIHF:
+ case llvm::Triple::GNUEABI:
++ case llvm::Triple::MuslEABIHF:
++ case llvm::Triple::MuslEABI:
+ case llvm::Triple::EABI:
+ CmdArgs.push_back("-meabi=5");
+ break;
+@@ -6888,10 +6894,12 @@
+ switch (getToolChain().getTriple().getEnvironment()) {
+ case llvm::Triple::EABI:
+ case llvm::Triple::GNUEABI:
++ case llvm::Triple::MuslEABI:
+ CmdArgs.push_back("armelf_nbsd_eabi");
+ break;
+ case llvm::Triple::EABIHF:
+ case llvm::Triple::GNUEABIHF:
++ case llvm::Triple::MuslEABIHF:
+ CmdArgs.push_back("armelf_nbsd_eabihf");
+ break;
+ default:
+@@ -6906,10 +6914,12 @@
+ switch (getToolChain().getTriple().getEnvironment()) {
+ case llvm::Triple::EABI:
+ case llvm::Triple::GNUEABI:
++ case llvm::Triple::MuslEABI:
+ CmdArgs.push_back("armelfb_nbsd_eabi");
+ break;
+ case llvm::Triple::EABIHF:
+ case llvm::Triple::GNUEABIHF:
++ case llvm::Triple::MuslEABIHF:
+ CmdArgs.push_back("armelfb_nbsd_eabihf");
+ break;
+ default:
+
--
2.1.4
diff --git a/main/llvm/clang-0007-musl-dynamic-linker-paths.patch b/main/llvm/clang-0007-musl-dynamic-linker-paths.patch
index c8b927fba3..fe04af2254 100644
--- a/main/llvm/clang-0007-musl-dynamic-linker-paths.patch
+++ b/main/llvm/clang-0007-musl-dynamic-linker-paths.patch
@@ -27,9 +27,9 @@ index 75eef9e..3e71522 100644
+ switch (ToolChain.getTriple().getEnvironment()) {
+ case llvm::Triple::Musl:
+ case llvm::Triple::MuslEABI:
-+ return "/lib/ld-musl-arm.so.3";
++ return "/lib/ld-musl-arm.so.1";
+ case llvm::Triple::MuslEABIHF:
-+ return "/lib/ld-musl-armhf.so.3";
++ return "/lib/ld-musl-armhf.so.1";
+ case llvm::Triple::GNUEABIHF:
return "/lib/ld-linux-armhf.so.3";
- else
diff --git a/main/llvm/llvm-0002-musl-triple.patch b/main/llvm/llvm-0002-musl-triple.patch
index aba274a7b7..6e6569fed9 100644
--- a/main/llvm/llvm-0002-musl-triple.patch
+++ b/main/llvm/llvm-0002-musl-triple.patch
@@ -37,6 +37,16 @@ index 0838e90..4be78e5 100644
.StartsWith("msvc", Triple::MSVC)
.StartsWith("itanium", Triple::Itanium)
.StartsWith("cygnus", Triple::Cygnus)
+--- llvm-3.6.1.src.orig/lib/Support/Triple.cpp
++++ llvm-3.6.1.src/lib/Support/Triple.cpp
+@@ -1094,6 +1094,7 @@
+ switch (getEnvironment()) {
+ case llvm::Triple::EABIHF:
+ case llvm::Triple::GNUEABIHF:
++ case llvm::Triple::MuslEABIHF:
+ return "arm1176jzf-s";
+ default:
+ return "arm7tdmi";
diff --git a/lib/Target/ARM/ARMSubtarget.h b/lib/Target/ARM/ARMSubtarget.h
index dbacd4d..b330be5 100644
--- a/lib/Target/ARM/ARMSubtarget.h