aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--testing/vlc/APKBUILD (renamed from unstable/vlc/APKBUILD)61
-rw-r--r--testing/vlc/uclibc-inhibit-spawn.patch35
-rw-r--r--testing/vlc/uclibc-libcompat.patch81
-rw-r--r--testing/vlc/uclibc3.patch49
-rw-r--r--unstable/vlc/uclibc.patch65
5 files changed, 211 insertions, 80 deletions
diff --git a/unstable/vlc/APKBUILD b/testing/vlc/APKBUILD
index d28ddf074c..bc12c857ee 100644
--- a/unstable/vlc/APKBUILD
+++ b/testing/vlc/APKBUILD
@@ -1,6 +1,6 @@
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=vlc
-pkgver=1.0.0
+pkgver=1.1.1
pkgrel=0
pkgdesc="A multi-platform MPEG, VCD/DVD, and DivX player"
url="http://www.videolan.org/vlc/"
@@ -14,8 +14,13 @@ depends="ttf-dejavu"
makedepends="
a52dec-dev
alsa-lib-dev
+ automake
+ autoconf
+ libtool
dbus-dev
+ faad2-dev
ffmpeg-dev
+ flac-dev
fribidi-dev
gtk+-dev
libgcrypt-dev
@@ -26,10 +31,12 @@ makedepends="
libnotify-dev
libogg-dev
libsm-dev
+ libtheora-dev
libx11-dev
libxext-dev
libxv-dev
lua-dev
+ ncurses-dev
mesa-dev
pkgconfig
sdl-dev
@@ -37,15 +44,30 @@ makedepends="
x264-dev
"
source="http://download.videolan.org/pub/videolan/$pkgname/$pkgver/$pkgname-$pkgver.tar.bz2
- uclibc.patch
+ uclibc3.patch
+ uclibc-libcompat.patch
+ uclibc-inhibit-spawn.patch
"
+_builddir="$srcdir"/$pkgname-$pkgver
+prepare() {
+ cd "$_builddir"
+ for i in $source; do
+ case $i in
+ *.patch)
+ msg "Applying $i"
+ patch -p1 -i "$srcdir"/$i || return 1
+ ;;
+ esac;
+ done
+ ./bootstrap
+}
+
build ()
{
- cd "$srcdir"/$pkgname-$pkgver
+ cd "$_builddir"
sed -i -e 's:/usr/share/fonts/truetype/freefont/FreeSerifBold.ttf:/usr/share/fonts/TTF/DejaVuSerif-Bold.ttf:' modules/misc/freetype.c
- patch -p1 < ../uclibc.patch || return 1
export CFLAGS="$CFLAGS -D_GNU_SOURCE"
./configure --prefix=/usr \
@@ -54,37 +76,46 @@ build ()
--disable-optimizations \
--disable-qt4 --disable-skins2 \
--disable-rpath \
+ --enable-dbus \
+ --enable-dbus-control \
+ --enable-faad \
+ --enable-flac \
--enable-httpd \
+ --enable-ncurses \
--enable-realrtsp \
+ --enable-sdl \
--enable-sout \
+ --enable-theora \
--enable-vlm \
+ --enable-xvideo \
|| return 1
# --enable-dvdread \
# --enable-dvdnav \
# --enable-qt4 \
-# --enable-faad \
# --enable-skins2 \
# --enable-dvb \
# --enable-v4l \
-# --enable-theora \
-# --enable-flac \
# --enable-snapshot \
# --enable-hal \
-# --enable-dbus \
-# --enable-dbus-control \
# --enable-lirc \
# --enable-shout \
# --enable-pvr \
make || return 1
+}
+
+package() {
+ cd "$_builddir"
make DESTDIR="$pkgdir"/ install || return 1
- for res in 16 32 48 128; do
- install -D -m644 share/vlc${res}x${res}.png \
- "$pkgdir"/usr/share/icons/hicolor/${res}x${res}/apps/vlc.png || return 1
- done
+# for res in 16 32 48 128; do
+# install -D -m644 share/vlc${res}x${res}.png \
+# "$pkgdir"/usr/share/icons/hicolor/${res}x${res}/apps/vlc.png || return 1
+# done
rm -rf "$pkgdir"/usr/lib/mozilla
}
-md5sums="fc78904ab5fa73f518d8fe4e852e7f67 vlc-1.0.0.tar.bz2
-2a16bf6c14a94f41490872aa189db755 uclibc.patch"
+md5sums="7e177faa61450ce752b0fd89ecc81fed vlc-1.1.1.tar.bz2
+4f74dcde9ce51c15d80c3876b85c05f2 uclibc3.patch
+d718e22a7de9f38579f276f720b2f36a uclibc-libcompat.patch
+361d6ae9d7b846833ed31e8454074158 uclibc-inhibit-spawn.patch"
diff --git a/testing/vlc/uclibc-inhibit-spawn.patch b/testing/vlc/uclibc-inhibit-spawn.patch
new file mode 100644
index 0000000000..9a6be5bd6a
--- /dev/null
+++ b/testing/vlc/uclibc-inhibit-spawn.patch
@@ -0,0 +1,35 @@
+diff --git a/modules/misc/inhibit/xdg.c b/modules/misc/inhibit/xdg.c
+index 01decac..134c5c9 100644
+--- a/modules/misc/inhibit/xdg.c
++++ b/modules/misc/inhibit/xdg.c
+@@ -25,7 +25,12 @@
+ #include <vlc_common.h>
+ #include <vlc_plugin.h>
+ #include <vlc_inhibit.h>
+-#include <spawn.h>
++#if !defined(_POSIX_SPAWN)
++# define _POSIX_SPAWN -1
++#else
++# include <spawn.h>
++#endif
++
+ #include <sys/wait.h>
+
+ static int Open (vlc_object_t *);
+@@ -125,8 +130,15 @@ static void *Thread (void *data)
+ };
+ pid_t pid;
+ int canc = vlc_savecancel ();
+-
++#if (_POSIX_SPAWN >= 0)
+ if (!posix_spawnp (&pid, "xdg-screensaver", NULL, NULL, argv, environ))
++#else
++ pid = fork();
++ if (pid == 0) {
++ execvp("xdg-screensaver", argv);
++ exit(1);
++ } else if (pid > 0)
++#endif
+ {
+ int status;
+
diff --git a/testing/vlc/uclibc-libcompat.patch b/testing/vlc/uclibc-libcompat.patch
new file mode 100644
index 0000000000..e4008002f4
--- /dev/null
+++ b/testing/vlc/uclibc-libcompat.patch
@@ -0,0 +1,81 @@
+commit c605c09bbc29d88619264c55c371c9dcbc839eda
+Author: Natanael Copa <ncopa@alpinelinux.org>
+Date: Thu Jul 29 19:20:17 2010 +0000
+
+ build: libcompat fix in case there are no functions to replace
+
+ If the libc provides all the funcs in libcompat the libcompat.a will
+ never be created due to LIBOBJS is empty (normally it contains whatever
+ AC_REPLACE_FUNCS detects). This happens on uclibc.
+
+ Since Makefile.am have a hardcoded LDADD to ../compat/libcompat.la things
+ goes bad when there is no libcompat.a at all. We solve this by checking
+ if LIBOBJS is set by AC_REPLACE_FUNCS and add libcompat via LTLIBCOMPAT.
+
+ For alternative fixes see http://www.gnu.org/software/hello/manual/automake/LIBOBJS.html
+
+diff --git a/bin/Makefile.am b/bin/Makefile.am
+index 92e6879..a941d99 100644
+--- a/bin/Makefile.am
++++ b/bin/Makefile.am
+@@ -60,5 +60,5 @@ vlc_win32_rc.$(OBJEXT): vlc_win32_rc.rc
+ vlc_cache_gen_SOURCES = cachegen.c
+ vlc_cache_gen_LDADD = \
+ $(GNUGETOPT_LIBS) \
+- ../compat/libcompat.la \
++ $(LTLIBCOMPAT) \
+ ../src/libvlc.la ../src/libvlccore.la
+diff --git a/configure.ac b/configure.ac
+index 52e4830..b385100 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -547,6 +547,14 @@ need_libc=false
+ dnl Check for usual libc functions
+ AC_CHECK_FUNCS([ctime_r daemon fcntl fdopendir fstatvfs fork getenv getpwuid_r gettimeofday isatty lstat memalign openat posix_fadvise posix_madvise posix_memalign setenv setlocale stricmp strnicmp tdestroy uselocale])
+ AC_REPLACE_FUNCS([asprintf atof atoll getcwd getdelim getpid gmtime_r lldiv localtime_r nrand48 rewind strcasecmp strcasestr strdup strlcpy strncasecmp strndup strnlen strsep strtof strtok_r strtoll swab vasprintf])
++
++dnl Check that we actually need libcompat
++LTLIBCOMPAT=""
++if test "x${LIBOBJS}" != "x"; then
++ LTLIBCOMPAT="\$(top_builddir)/compat/libcompat.la"
++fi
++AC_SUBST(LTLIBCOMPAT)
++
+ AC_CHECK_FUNCS(fdatasync,,
+ [AC_DEFINE(fdatasync, fsync, [Alias fdatasync() to fsync() if missing.])
+ ])
+diff --git a/modules/common.am b/modules/common.am
+index 5e4d65f..9e2c739 100644
+--- a/modules/common.am
++++ b/modules/common.am
+@@ -24,7 +24,7 @@ AM_LDFLAGS = -rpath '$(libvlcdir)' \
+ -no-undefined \
+ `$(VLC_CONFIG) --ldflags plugin $@`
+ AM_LIBADD = `$(VLC_CONFIG) -libs plugin $@` \
+- $(LTLIBVLCCORE) $(top_builddir)/compat/libcompat.la
++ $(LTLIBVLCCORE) $(LTLIBCOMPAT)
+
+ include $(srcdir)/Modules.am
+
+diff --git a/src/Makefile.am b/src/Makefile.am
+index f46a154..6aad884 100644
+--- a/src/Makefile.am
++++ b/src/Makefile.am
+@@ -201,7 +201,7 @@ libvlccore_la_LDFLAGS = `$(VLC_CONFIG) --ldflags libvlccore` $(AM_LDFLAGS) \
+ -export-symbols $(srcdir)/libvlccore.sym \
+ -version-info 5:0:0
+ libvlccore_la_LIBADD = `$(VLC_CONFIG) -libs libvlccore` $(AM_LIBADD) \
+- $(LTLIBINTL) ../compat/libcompat.la
++ $(LTLIBINTL) $(LTLIBCOMPAT)
+ libvlccore_la_DEPENDENCIES = libvlccore.sym
+ if HAVE_WIN32
+ libvlccore_la_DEPENDENCIES += libvlc_win32_rc.$(OBJEXT)
+@@ -214,7 +214,7 @@ libvlc_win32_rc.$(OBJEXT): libvlc_win32_rc.rc
+ libvlc_la_SOURCES = $(SOURCES_libvlc_control)
+ nodist_libvlc_la_SOURCES = revision.c
+ libvlc_la_LIBADD = `$(VLC_CONFIG) -libs libvlc` \
+- libvlccore.la ../compat/libcompat.la
++ libvlccore.la $(LTLIBCOMPAT)
+ libvlc_la_CFLAGS = `$(VLC_CONFIG) --cflags libvlc`
+ libvlc_la_LDFLAGS = $(AM_LDFLAGS) `$(VLC_CONFIG) --ldflags libvlc` \
+ -version-info 6:0:1 \
diff --git a/testing/vlc/uclibc3.patch b/testing/vlc/uclibc3.patch
new file mode 100644
index 0000000000..04154f35bf
--- /dev/null
+++ b/testing/vlc/uclibc3.patch
@@ -0,0 +1,49 @@
+diff --git a/src/control/vlm.c b/src/control/vlm.c
+index 05417e5..46fa957 100644
+--- a/src/control/vlm.c
++++ b/src/control/vlm.c
+@@ -25,6 +25,10 @@
+ # include <config.h>
+ #endif
+
++#ifdef HAVE_CONFIG_H
++# include "config.h"
++#endif
++
+ #include <vlc/libvlc.h>
+ #include <vlc/libvlc_vlm.h>
+ #include <vlc_es.h>
+diff --git a/src/misc/linux_specific.c b/src/misc/linux_specific.c
+index 1644ce6..1440e1c 100644
+--- a/src/misc/linux_specific.c
++++ b/src/misc/linux_specific.c
+@@ -83,14 +83,14 @@ static struct
+ unsigned refs;
+ } once = { VLC_STATIC_MUTEX, 0 };
+
+-#ifdef __GLIBC__
++#if defined(__GLIBC__) && !defined(__UCLIBC__)
+ # include <gnu/libc-version.h>
+ # include <stdlib.h>
+ #endif
+
+ void system_Init (libvlc_int_t *libvlc, int *argc, const char *argv[])
+ {
+-#ifdef __GLIBC__
++#if defined(__GLIBC__) && !defined(__UCLIBC__)
+ const char *glcv = gnu_get_libc_version ();
+
+ /* gettext in glibc 2.5-2.7 is not thread-safe. LibVLC keeps crashing,
+diff --git a/src/misc/mtime.c b/src/misc/mtime.c
+index 1cc787d..985aa3a 100644
+--- a/src/misc/mtime.c
++++ b/src/misc/mtime.c
+@@ -78,7 +78,7 @@ int nanosleep(struct timespec *, struct timespec *);
+ # define _POSIX_CLOCK_SELECTION (-1)
+ #endif
+
+-# if (_POSIX_CLOCK_SELECTION < 0)
++# if (_POSIX_CLOCK_SELECTION < 0) || defined(__UCLIBC__)
+ /*
+ * We cannot use the monotonic clock if clock selection is not available,
+ * as it would screw vlc_cond_timedwait() completely. Instead, we have to
diff --git a/unstable/vlc/uclibc.patch b/unstable/vlc/uclibc.patch
deleted file mode 100644
index f71b189a4c..0000000000
--- a/unstable/vlc/uclibc.patch
+++ /dev/null
@@ -1,65 +0,0 @@
---- a/src/misc/linux_specific.c 2009-07-08 09:29:41.000000000 +0000
-+++ b/src/misc/linux_specific.c 2009-07-08 09:30:47.000000000 +0000
-@@ -72,14 +72,14 @@
- }
- #endif
-
--#ifdef __GLIBC__
-+#if defined(__GLIBC__) && !defined(__UCLIBC__)
- # include <gnu/libc-version.h>
- # include <stdlib.h>
- #endif
-
- void system_Init (libvlc_int_t *libvlc, int *argc, const char *argv[])
- {
--#ifdef __GLIBC__
-+#if defined(__GLIBC__) && !defined(__UCLIBC__)
- const char *glcv = gnu_get_libc_version ();
-
- /* gettext in glibc 2.5-2.7 is not thread-safe. LibVLC keeps crashing,
---- a/src/control/vlm.c 2009-07-09 09:21:55.000000000 +0000
-+++ b/src/control/vlm.c 2009-07-09 09:22:24.000000000 +0000
-@@ -21,6 +21,10 @@
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
- *****************************************************************************/
-
-+#ifdef HAVE_CONFIG_H
-+# include "config.h"
-+#endif
-+
- #include <vlc/libvlc.h>
- #include <vlc/libvlc_vlm.h>
- #include <vlc_es.h>
---- a/src/misc/mtime.c 2009-07-09 11:57:46.000000000 +0000
-+++ b/src/misc/mtime.c 2009-07-09 13:48:16.000000000 +0000
-@@ -78,7 +78,7 @@
- # define _POSIX_CLOCK_SELECTION (-1)
- #endif
-
--# if (_POSIX_CLOCK_SELECTION < 0)
-+# if (_POSIX_CLOCK_SELECTION < 0) || defined(__UCLIBC__)
- /*
- * We cannot use the monotonic clock is clock selection is not available,
- * as it would screw vlc_cond_timedwait() completely. Instead, we have to
---- a/src/misc/threads.c 2009-07-09 13:54:08.000000000 +0000
-+++ b/src/misc/threads.c 2009-07-09 13:54:32.000000000 +0000
-@@ -474,7 +474,7 @@
- /* Fairly outdated POSIX support (that was defined in 2001) */
- # define _POSIX_CLOCK_SELECTION (-1)
- # endif
--# if (_POSIX_CLOCK_SELECTION >= 0)
-+# if (_POSIX_CLOCK_SELECTION >= 0) && !defined(__UCLIBC__)
- /* NOTE: This must be the same clock as the one in mtime.c */
- pthread_condattr_setclock (&attr, CLOCK_MONOTONIC);
- # endif
---- a/modules/stream_filter/decomp.c 2009-07-09 14:10:09.000000000 +0000
-+++ b/modules/stream_filter/decomp.c 2009-07-09 14:11:37.000000000 +0000
-@@ -28,7 +28,7 @@
- #include <vlc_network.h>
- #include <assert.h>
- #include <unistd.h>
--#ifndef _POSIX_SPAWN
-+#if !defined(_POSIX_SPAWN) || defined(__UCLIBC__)
- # define _POSIX_SPAWN (-1)
- #endif
- #include <fcntl.h>