[vlc-commits] Fixing weak alias detection for llvm based compilers

Olivier Gambier git at videolan.org
Wed Jan 18 01:54:48 CET 2012


vlc | branch: master | Olivier Gambier <olivier at webitup.fr> | Wed Jan 18 01:41:28 2012 +0100| [dbedba79a4c61d3ea609a94afa07f4a7ddbf2d59] | committer: Rafaël Carré

Fixing weak alias detection for llvm based compilers

Signed-off-by: Rafaël Carré <funman at videolan.org>

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=dbedba79a4c61d3ea609a94afa07f4a7ddbf2d59
---

 contrib/src/caca/caca-llvm-weak-alias.patch |   11 +++++++++++
 contrib/src/caca/rules.mak                  |    2 ++
 2 files changed, 13 insertions(+), 0 deletions(-)

diff --git a/contrib/src/caca/caca-llvm-weak-alias.patch b/contrib/src/caca/caca-llvm-weak-alias.patch
new file mode 100644
index 0000000..b9f2892
--- /dev/null
+++ b/contrib/src/caca/caca-llvm-weak-alias.patch
@@ -0,0 +1,11 @@
+--- libcaca/caca/caca.h 2011-07-05 00:09:51.000000000 -0700
++++ libcaca.new/caca/caca.h 2011-07-05 00:10:10.000000000 -0700
+@@ -645,7 +645,7 @@
+ #       define CACA_DEPRECATED
+ #   endif
+ 
+-#   if defined __GNUC__ && __GNUC__ > 3
++#   if !(defined __APPLE__ && defined __llvm__) && defined __GNUC__ && __GNUC__ > 3
+ #       define CACA_ALIAS(x) __attribute__ ((weak, alias(#x)))
+ #   else
+ #       define CACA_ALIAS(x)
diff --git a/contrib/src/caca/rules.mak b/contrib/src/caca/rules.mak
index ebf37cb..7477675 100644
--- a/contrib/src/caca/rules.mak
+++ b/contrib/src/caca/rules.mak
@@ -17,6 +17,8 @@ caca: libcaca-$(CACA_VERSION).tar.gz .sum-caca
 ifdef HAVE_MACOSX
 	$(APPLY) $(SRC)/caca/caca-osx-sdkofourchoice.patch
 endif
+	$(APPLY) $(SRC)/caca/caca-llvm-weak-alias.patch
+
 ifdef HAVE_WIN32
 	$(APPLY) $(SRC)/caca/caca-win32-static.patch
 endif



More information about the vlc-commits mailing list