[vlc-commits] Contribs: add libcaca
Jean-Baptiste Kempf
git at videolan.org
Fri Oct 14 00:48:40 CEST 2011
vlc | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Fri Oct 14 00:47:10 2011 +0200| [268c223ff0878b03b35d1100c76deac750fc039f] | committer: Jean-Baptiste Kempf
Contribs: add libcaca
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=268c223ff0878b03b35d1100c76deac750fc039f
---
contrib/src/caca/SHA512SUMS | 1 +
contrib/src/caca/caca-osx-sdkofourchoice.patch | 39 ++++++++++++++++++++++++
contrib/src/caca/caca-win32-static.patch | 11 +++++++
contrib/src/caca/rules.mak | 32 +++++++++++++++++++
4 files changed, 83 insertions(+), 0 deletions(-)
diff --git a/contrib/src/caca/SHA512SUMS b/contrib/src/caca/SHA512SUMS
new file mode 100644
index 0000000..1589ba9
--- /dev/null
+++ b/contrib/src/caca/SHA512SUMS
@@ -0,0 +1 @@
+1d08a45a742cbda2c80810e753b49588cb9073ef545a1d47537745c4e62dc79748a25907903ffee58676d9aa5b75c5e0658666429cf028e10c09157d418c8d19 libcaca-0.99.beta17.tar.gz
diff --git a/contrib/src/caca/caca-osx-sdkofourchoice.patch b/contrib/src/caca/caca-osx-sdkofourchoice.patch
new file mode 100644
index 0000000..586672f
--- /dev/null
+++ b/contrib/src/caca/caca-osx-sdkofourchoice.patch
@@ -0,0 +1,39 @@
+--- libcaca/configure.orig 2010-02-08 14:46:58.000000000 +0100
++++ libcaca/configure 2010-08-09 17:46:59.000000000 +0200
+@@ -16785,33 +16785,9 @@
+ done
+
+ if test "${ac_cv_my_have_cocoa}" = "yes"; then
+- case x${target} in
+- xpowerpc*darwin*)
+- # 10.3 needed to link with X11
+- MACOSX_SDK="${MACOSX_SDK:-/Developer/SDKs/MacOSX10.3.9.sdk}"
+- GCC_VERSION="${GCC_VERSION:-3.3}"
+- ARCH="${ARCH:--arch ppc}"
+- MACOSX_SDK_CFLAGS="${MACOSX_SDK_CFLAGS:--nostdinc -isystem ${MACOSX_SDK}/usr/include/gcc/darwin/${GCC_VERSION} -isystem ${MACOSX_SDK}/usr/include}"
+- MACOSX_SDK_CXXFLAGS="${MACOSX_SDK_CXXFLAGS:--nostdinc++ -I${MACOSX_SDK}/usr/include/gcc/darwin/${GCC_VERSION}/c++ -I${MACOSX_SDK}/usr/include/gcc/darwin/${GCC_VERSION}/c++/ppc-darwin -I${MACOSX_SDK}/usr/include/gcc/darwin/${GCC_VERSION}/c++/backward}"
+- MACOSX_SDK_LDFLAGS="${MACOSX_SDK_LDFLAGS:--L${MACOSX_SDK}/usr/lib/gcc/darwin -L${MACOSX_SDK}/usr/lib/gcc/darwin/${GCC_VERSION} -L${MACOSX_SDK}/usr/lib}"
+- ;;
+- x*86_64*darwin*)
+- MACOSX_SDK="${MACOSX_SDK:-/Developer/SDKs/MacOSX10.5.sdk}"
+- GCC_VERSION="${GCC_VERSION:-4.0}"
+- ARCH="${ARCH:--arch i386}"
+- MACOSX_SDK_CFLAGS="${MACOSX_SDK_CFLAGS:--isysroot ${MACOSX_SDK}}"
+- MACOSX_SDK_CXXFLAGS="${MACOSX_SDK_CXXFLAGS:-${MACOSX_SDK_CFLAGS}}"
+- ;;
+- x*86*darwin*)
+- MACOSX_SDK="${MACOSX_SDK:-/Developer/SDKs/MacOSX10.6.sdk}"
+- GCC_VERSION="${GCC_VERSION:-4.0}"
+- ARCH="${ARCH:--arch i386}"
+- MACOSX_SDK_CFLAGS="${MACOSX_SDK_CFLAGS:--isysroot ${MACOSX_SDK}}"
+- MACOSX_SDK_CXXFLAGS="${MACOSX_SDK_CXXFLAGS:-${MACOSX_SDK_CFLAGS}}"
+- ;;
+- esac
+- CC="${CC:-gcc-${GCC_VERSION}}"
+- CXX="${CXX:-g++-${GCC_VERSION}}"
++ MACOSX_SDK=/Developer/SDKs/MacOSX10.5.sdk
++ MACOSX_SDK_CFLAGS="-isysroot ${MACOSX_SDK}"
++ MACOSX_SDK_CXXFLAGS="${MACOSX_SDK_CFLAGS}"
+ MACOSX_SDK_FRAMEWORKS="${MACOSX_SDK_FRAMEWORKS:--F${MACOSX_SDK}/System/Library/Frameworks}"
+ CPPFLAGS="${CPPFLAGS} ${ARCH} ${MACOSX_SDK_FRAMEWORKS}"
+ CFLAGS="${CFLAGS} ${MACOSX_SDK_CFLAGS}"
diff --git a/contrib/src/caca/caca-win32-static.patch b/contrib/src/caca/caca-win32-static.patch
new file mode 100644
index 0000000..87cd4e1
--- /dev/null
+++ b/contrib/src/caca/caca-win32-static.patch
@@ -0,0 +1,11 @@
+--- libcaca/caca/caca.h 2010-02-08 13:34:28.000000000 +0100
++++ libcaca.new/caca/caca.h 2010-08-24 19:27:39.000000000 +0200
+@@ -31,7 +31,7 @@
+ #if defined _DOXYGEN_SKIP_ME
+ #elif defined _WIN32 && defined __LIBCACA__ && defined DLL_EXPORT
+ # define __extern extern __declspec(dllexport)
+-#elif defined _WIN32 && !defined __LIBCACA__
++#elif defined _WIN32 && !defined __LIBCACA__ && defined __NULL
+ # define __extern extern __declspec(dllimport)
+ #else
+ # define __extern extern
diff --git a/contrib/src/caca/rules.mak b/contrib/src/caca/rules.mak
new file mode 100644
index 0000000..992f24f
--- /dev/null
+++ b/contrib/src/caca/rules.mak
@@ -0,0 +1,32 @@
+# CACA
+CACA_VERSION := 0.99.beta17
+CACA_URL := http://caca.zoy.org/files/libcaca/libcaca-$(CACA_VERSION).tar.gz
+
+PKGS += caca
+ifeq ($(call need_pkg,"caca >= 0.99.beta14"),)
+PKGS_FOUND += caca
+endif
+
+$(TARBALLS)/libcaca-$(CACA_VERSION).tar.gz:
+ $(call download,$(CACA_URL))
+
+.sum-caca: libcaca-$(CACA_VERSION).tar.gz
+
+caca: libcaca-$(CACA_VERSION).tar.gz .sum-caca
+ $(UNPACK)
+ifdef HAVE_MACOSX
+ $(APPLY) $(SRC)/caca/caca-osx-sdkofourchoice.patch
+endif
+ifdef HAVE_WIN32
+ $(APPLY) $(SRC)/caca/caca-win32-static.patch
+endif
+ $(MOVE)
+
+.caca: caca
+ifdef HAVE_MACOSX
+ cd $< && $(HOSTVARS) ./configure $(HOSTCONF) --disable-imlib2 --disable-doc --disable-ruby --disable-csharp --disable-cxx --disable-x11
+else
+ cd $< && $(HOSTVARS) ./configure $(HOSTCONF) --disable-imlib2 --disable-doc --disable-ruby --disable-csharp --disable-cxx
+endif
+ cd $< && $(MAKE) -C $< install
+ touch $@
More information about the vlc-commits
mailing list