]> git.sesse.net Git - vlc/commitdiff
contrib/theora: fix broken compiler differenciation
authorFelix Paul Kühne <fkuehne@videolan.org>
Sat, 14 Jun 2014 10:39:44 +0000 (12:39 +0200)
committerFelix Paul Kühne <fkuehne@videolan.org>
Sun, 15 Jun 2014 17:27:33 +0000 (19:27 +0200)
This solves compilation issues from the future.

contrib/src/theora/libtheora-compiler-differentiation.patch [new file with mode: 0644]
contrib/src/theora/rules.mak

diff --git a/contrib/src/theora/libtheora-compiler-differentiation.patch b/contrib/src/theora/libtheora-compiler-differentiation.patch
new file mode 100644 (file)
index 0000000..872ebc1
--- /dev/null
@@ -0,0 +1,25 @@
+diff -ru libtheora/configure.ac libtheora-fixed/configure.ac
+--- libtheora/configure.ac     2009-10-01 20:00:33.000000000 +0200
++++ libtheora-fixed/configure.ac       2014-06-13 20:21:16.000000000 +0200
+@@ -155,8 +155,20 @@
+ dnl Set some target options
++cc_compiler=unknown
++AC_COMPILE_IFELSE([AC_LANG_SOURCE([[#if ! __clang__
++                                    #error
++                                    #endif
++                                    ]])],
++                  cc_compiler=clang,
++                  [AC_COMPILE_IFELSE([AC_LANG_SOURCE([[#if ! __GNUC__
++                                                       #error
++                                                       #endif
++                                                       ]])],
++                                     cc_compiler=gcc, [])])
++
+ cflags_save="$CFLAGS"
+-if test -z "$GCC"; then
++if test $cc_compiler != "gcc" ; then
+         case $host in 
+         *)
+                 DEBUG="-g -DDEBUG"
index 40247882c4d4975a396b85e7b82a6cb4bbcacf3a..ea4c879aa4f5d74de6d5a400626bc5d65b95a088 100644 (file)
@@ -16,6 +16,7 @@ $(TARBALLS)/libtheora-$(THEORA_VERSION).tar.xz:
 
 libtheora: libtheora-$(THEORA_VERSION).tar.xz .sum-theora
        $(UNPACK)
+       $(APPLY) $(SRC)/theora/libtheora-compiler-differentiation.patch
        $(UPDATE_AUTOCONFIG)
        $(MOVE)