[vlc-commits] contrib: fix schroedinger build with android toolchain
Rafaël Carré
git at videolan.org
Thu Jan 5 23:19:02 CET 2012
vlc/vlc-1.2 | branch: master | Rafaël Carré <funman at videolan.org> | Wed Dec 28 10:24:21 2011 -0500| [2cb5558519125f4a7243581db6dc9f7eee69a2f4] | committer: Jean-Baptiste Kempf
contrib: fix schroedinger build with android toolchain
google's gcc doesn't understand 'restrict'. Use __restrict__
(cherry picked from commit 9f3cdb0791751d638311fe442bae5b8cc0e46408)
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>
> http://git.videolan.org/gitweb.cgi/vlc/vlc-1.2.git/?a=commit;h=2cb5558519125f4a7243581db6dc9f7eee69a2f4
---
contrib/src/schroedinger/android.patch | 11 +++++++++++
contrib/src/schroedinger/rules.mak | 1 +
2 files changed, 12 insertions(+), 0 deletions(-)
diff --git a/contrib/src/schroedinger/android.patch b/contrib/src/schroedinger/android.patch
new file mode 100644
index 0000000..a5be6fe
--- /dev/null
+++ b/contrib/src/schroedinger/android.patch
@@ -0,0 +1,11 @@
+--- schroedinger/schroedinger/schroorc-dist.c.orig 2011-12-28 10:22:01.620224002 -0500
++++ schroedinger/schroedinger/schroorc-dist.c 2011-12-28 10:22:12.880224003 -0500
+@@ -200,7 +200,7 @@
+ #define ORC_ISNAN(x) ((((x)&0x7f800000) == 0x7f800000) && (((x)&0x007fffff) != 0))
+ #define ORC_DENORMAL_DOUBLE(x) ((x) & ((((x)&ORC_UINT64_C(0x7ff0000000000000)) == 0) ? ORC_UINT64_C(0xfff0000000000000) : ORC_UINT64_C(0xffffffffffffffff)))
+ #define ORC_ISNAN_DOUBLE(x) ((((x)&ORC_UINT64_C(0x7ff0000000000000)) == ORC_UINT64_C(0x7ff0000000000000)) && (((x)&ORC_UINT64_C(0x000fffffffffffff)) != 0))
+-#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
++#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L && !defined(__ANDROID__)
+ #define ORC_RESTRICT restrict
+ #elif defined(__GNUC__) && __GNUC__ >= 4
+ #define ORC_RESTRICT __restrict__
diff --git a/contrib/src/schroedinger/rules.mak b/contrib/src/schroedinger/rules.mak
index cf0b1f8..ebecc9e 100644
--- a/contrib/src/schroedinger/rules.mak
+++ b/contrib/src/schroedinger/rules.mak
@@ -16,6 +16,7 @@ $(TARBALLS)/schroedinger-$(SCHROEDINGER_VERSION).tar.gz:
schroedinger: schroedinger-$(SCHROEDINGER_VERSION).tar.gz .sum-schroedinger
$(UNPACK)
$(APPLY) $(SRC)/schroedinger/schroedinger-notests.patch
+ $(APPLY) $(SRC)/schroedinger/android.patch
$(MOVE)
DEPS_schroedinger = orc $(DEPS_orc)
More information about the vlc-commits
mailing list