aboutsummaryrefslogtreecommitdiffstats
path: root/testing/llvm3.7/llvm-0002-Fix-build-with-musl-libc.patch
diff options
context:
space:
mode:
authorMitch Tishmack <mitch.tishmack@gmail.com>2016-07-14 21:53:19 -0500
committerBartłomiej Piotrowski <b@bpiotrowski.pl>2016-07-25 20:29:38 +0200
commitdf54f12335b3c9c456f29258ae7a98d14d7bdcf4 (patch)
treed432b55d7aae5ed38609ea93bfab7cd5d8887f67 /testing/llvm3.7/llvm-0002-Fix-build-with-musl-libc.patch
parent199658c24c0fa59006887f974705208ef0dbb25f (diff)
downloadaports-df54f12335b3c9c456f29258ae7a98d14d7bdcf4.tar.bz2
aports-df54f12335b3c9c456f29258ae7a98d14d7bdcf4.tar.xz
testing/llvm3.7: new aport
Diffstat (limited to 'testing/llvm3.7/llvm-0002-Fix-build-with-musl-libc.patch')
-rw-r--r--testing/llvm3.7/llvm-0002-Fix-build-with-musl-libc.patch35
1 files changed, 35 insertions, 0 deletions
diff --git a/testing/llvm3.7/llvm-0002-Fix-build-with-musl-libc.patch b/testing/llvm3.7/llvm-0002-Fix-build-with-musl-libc.patch
new file mode 100644
index 0000000000..1a69080866
--- /dev/null
+++ b/testing/llvm3.7/llvm-0002-Fix-build-with-musl-libc.patch
@@ -0,0 +1,35 @@
+From 5c571082fdaf61f6df19d9b7137dc26d71334058 Mon Sep 17 00:00:00 2001
+From: Natanael Copa <ncopa@alpinelinux.org>
+Date: Thu, 18 Feb 2016 10:33:04 +0100
+Subject: [PATCH 2/3] Fix build with musl libc
+
+On musl libc the fopen64 and fopen are the same thing, but for
+compatibility they have a `#define fopen64 fopen`. Same applies for
+fseek64, fstat64, fstatvfs64, ftello64, lstat64, stat64 and tmpfile64.
+---
+ include/llvm/Analysis/TargetLibraryInfo.h | 9 +++++++++
+ 1 file changed, 9 insertions(+)
+
+diff --git a/include/llvm/Analysis/TargetLibraryInfo.h b/include/llvm/Analysis/TargetLibraryInfo.h
+index 7becdf0..7f14427 100644
+--- a/include/llvm/Analysis/TargetLibraryInfo.h
++++ b/include/llvm/Analysis/TargetLibraryInfo.h
+@@ -18,6 +18,15 @@
+ #include "llvm/IR/Module.h"
+ #include "llvm/Pass.h"
+
++#undef fopen64
++#undef fseeko64
++#undef fstat64
++#undef fstatvfs64
++#undef ftello64
++#undef lstat64
++#undef stat64
++#undef tmpfile64
++
+ namespace llvm {
+ /// VecDesc - Describes a possible vectorization of a function.
+ /// Function 'VectorFnName' is equivalent to 'ScalarFnName' vectorized
+--
+2.7.3
+