summaryrefslogtreecommitdiffstats
path: root/main/llvm/clang-3.1-alpine-linux.patch
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2012-07-04 13:12:51 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2012-07-04 13:13:13 +0000
commitc57e216aa51ed9a890c215aa1bfe3b1509724432 (patch)
tree5ad6655d2e12ac78bb5266535aa5148249b14e2e /main/llvm/clang-3.1-alpine-linux.patch
parent4e1efc2267a494a857b71fc13e8b64444e3d8ff9 (diff)
downloadaports-c57e216aa51ed9a890c215aa1bfe3b1509724432.tar.bz2
aports-c57e216aa51ed9a890c215aa1bfe3b1509724432.tar.xz
main/llvm: upgrade to 3.1
Diffstat (limited to 'main/llvm/clang-3.1-alpine-linux.patch')
-rw-r--r--main/llvm/clang-3.1-alpine-linux.patch62
1 files changed, 62 insertions, 0 deletions
diff --git a/main/llvm/clang-3.1-alpine-linux.patch b/main/llvm/clang-3.1-alpine-linux.patch
new file mode 100644
index 000000000..8214261d7
--- /dev/null
+++ b/main/llvm/clang-3.1-alpine-linux.patch
@@ -0,0 +1,62 @@
+--- ./tools/clang/lib/Driver/ToolChains.cpp.orig
++++ ./tools/clang/lib/Driver/ToolChains.cpp
+@@ -1198,7 +1198,8 @@
+ "x86_64-suse-linux",
+ "x86_64-manbo-linux-gnu",
+ "x86_64-linux-gnu",
+- "x86_64-slackware-linux"
++ "x86_64-slackware-linux",
++ "x86_64-alpine-linux-uclibc"
+ };
+ static const char *const X86LibDirs[] = { "/lib32", "/lib" };
+ static const char *const X86Triples[] = {
+@@ -1210,7 +1211,8 @@
+ "i586-redhat-linux",
+ "i386-redhat-linux",
+ "i586-suse-linux",
+- "i486-slackware-linux"
++ "i486-slackware-linux",
++ "i486-alpine-linux-uclibc"
+ };
+
+ static const char *const MIPSLibDirs[] = { "/lib" };
+@@ -1814,6 +1816,7 @@
+ /// Linux toolchain (very bare-bones at the moment).
+
+ enum LinuxDistro {
++ AlpineLinux,
+ ArchLinux,
+ DebianLenny,
+ DebianSqueeze,
+@@ -1935,6 +1938,9 @@
+
+ if (!llvm::sys::fs::exists("/etc/arch-release", Exists) && Exists)
+ return ArchLinux;
++
++ if (!llvm::sys::fs::exists("/etc/alpine-release", Exists) && Exists)
++ return AlpineLinux;
+
+ return UnknownDistro;
+ }
+diff --git a/tools/clang/lib/Driver/Tools.cpp b/tools/clang/lib/Driver/Tools.cpp
+index 6151e88..d811789 100644
+--- a/tools/clang/lib/Driver/Tools.cpp
++++ b/tools/clang/lib/Driver/Tools.cpp
+@@ -4308,7 +4308,7 @@ void linuxtools::Link::ConstructJob(Compilation &C, const JobAction &JA,
+ !Args.hasArg(options::OPT_shared))) {
+ CmdArgs.push_back("-dynamic-linker");
+ if (ToolChain.getArch() == llvm::Triple::x86)
+- CmdArgs.push_back("/lib/ld-linux.so.2");
++ CmdArgs.push_back("/lib/ld-uClibc.so.0.9.32");
+ else if (ToolChain.getArch() == llvm::Triple::arm ||
+ ToolChain.getArch() == llvm::Triple::thumb)
+ CmdArgs.push_back("/lib/ld-linux.so.3");
+@@ -4317,7 +4317,7 @@ void linuxtools::Link::ConstructJob(Compilation &C, const JobAction &JA,
+ else if (ToolChain.getArch() == llvm::Triple::ppc64)
+ CmdArgs.push_back("/lib64/ld64.so.1");
+ else
+- CmdArgs.push_back("/lib64/ld-linux-x86-64.so.2");
++ CmdArgs.push_back("/lib/ld64-uClibc.so.0.9.32");
+ }
+
+ CmdArgs.push_back("-o");