aboutsummaryrefslogtreecommitdiffstats
path: root/unmaintained
diff options
context:
space:
mode:
Diffstat (limited to 'unmaintained')
-rw-r--r--unmaintained/gnash/APKBUILD86
-rw-r--r--unmaintained/gnash/aslr-fix.patch52
-rw-r--r--unmaintained/gnash/gnash-0.8.10-giflib5.patch12
-rw-r--r--unmaintained/gnash/gnash-ffmpeg.patch24
4 files changed, 174 insertions, 0 deletions
diff --git a/unmaintained/gnash/APKBUILD b/unmaintained/gnash/APKBUILD
new file mode 100644
index 0000000000..12a9a468b8
--- /dev/null
+++ b/unmaintained/gnash/APKBUILD
@@ -0,0 +1,86 @@
+# Contributor: William Pitcock <nenolod@dereferenced.org>
+# Maintainer: William Pitcock <nenolod@dereferenced.org>
+pkgname=gnash
+pkgver=0.8.10
+pkgrel=7
+pkgdesc="GNU flash player implementation"
+url="http://www.gnashdev.org/"
+arch="all"
+license="GPL"
+depends=
+depends_dev="agg-dev cairo-dev gstreamer-dev gst-plugins-base-dev
+ mesa-dev gtk+-dev sdl-dev boost-dev giflib-dev
+ speex-dev libxml2-dev jpeg-dev xulrunner-dev gtkglext-dev
+ curl-dev libxmu-dev libx11-dev"
+makedepends="$depends_dev libtool"
+install=""
+subpackages="$pkgname-doc $pkgname-dev $pkgname-mozilla $pkgname-sdl
+ $pkgname-fb $pkgname-lang"
+source="http://ftp.gnu.org/pub/gnu/gnash/$pkgver/gnash-$pkgver.tar.bz2
+ gnash-ffmpeg.patch
+ aslr-fix.patch
+ gnash-0.8.10-giflib5.patch"
+
+_builddir="$srcdir"/gnash-$pkgver
+prepare() {
+ local i
+ cd "$_builddir"
+ for i in $source; do
+ case $i in
+ *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
+ esac
+ done
+ # append system-mt to avoid underlinking
+ sed -i -e 's/^[[:space:]]\+boost_libs="\(.*\)"/boost_libs="\1 system-mt"/' configure
+}
+
+build() {
+ cd "$_builddir"
+ ./configure --prefix=/usr \
+ --sysconfdir=/etc \
+ --mandir=/usr/share/man \
+ --infodir=/usr/share/info \
+ --localstatedir=/var \
+ --enable-media=gst \
+ --without-gconf \
+ || return 1
+ make || return 1
+}
+
+package() {
+ cd "$_builddir"
+ make DESTDIR="$pkgdir" install || return 1
+ rm "$pkgdir"/usr/lib/gnash/*.la || return 1
+}
+
+sdl() {
+ pkgdesc="$pkgdesc (sdl player)"
+ mkdir -p "$subpkgdir"/usr/bin
+ mv "$pkgdir"/usr/bin/sdl-gnash "$subpkgdir"/usr/bin
+}
+
+fb() {
+ pkgdesc="$pkgdesc (framebuffer player)"
+ mkdir -p "$subpkgdir"/usr/bin
+ mv "$pkgdir"/usr/bin/fb-gnash "$subpkgdir"/usr/bin
+}
+
+mozilla() {
+ depends="gnash"
+ pkgdesc="$pkgdesc (mozilla plugin)"
+ mkdir -p "$subpkgdir"/usr/lib/mozilla/plugins
+ mv "$_builddir"/plugin/npapi/.libs/libgnashplugin.so "$subpkgdir"/usr/lib/mozilla/plugins
+}
+
+md5sums="63e9f79c41d93d48c5a2fa94856548c4 gnash-0.8.10.tar.bz2
+b324b3fee1e017d8fcc4d991146266f8 gnash-ffmpeg.patch
+64cea4c0b4963b7fd5308beb1b20fed6 aslr-fix.patch
+d83b151957d2ecbe49321193b90422dd gnash-0.8.10-giflib5.patch"
+sha256sums="9625072e45df92baa2c28fc9999d4e2deb66bc827530baedfad2e4e2292d1224 gnash-0.8.10.tar.bz2
+8be32eb434fba546eddc2699939bd5e2d43898ff6953cac0ceb0a8ee781fcf69 gnash-ffmpeg.patch
+13bde56f92492c5cec4f7f60ce7c58042aa5b8d28195db8c34ae47794e3495d7 aslr-fix.patch
+d1597ce496d95913a7d5873a0a3c58e4f40fa4ec6e3fc7ae939a66f1362b3e57 gnash-0.8.10-giflib5.patch"
+sha512sums="4937782809b086dddd4c290de3893e8d8af677ac4d73bd37143aca2f210979222166f9ccb029f43a63f70c2e0820bb2432447067097fa1dfb1eba8365d07d85e gnash-0.8.10.tar.bz2
+b8b9739f01f7f2008e9c62dfcef2fc0732eab0ee7a587fa20da573e090d3cf965c1d607d7660386b946c4854aea13367fe6982698a2f2c5beac2565ff79f823c gnash-ffmpeg.patch
+1f93e114844607d7e2719dd5e10bc758f6e684f77ad70dcb64e2dba89d6e40849117ad6700baa8497860494bfc43d637a33a85927135e140e5c4c90098295596 aslr-fix.patch
+8fb96df3ba38297dc66277c1d15d7a93e91b10c24f0ac94f1a19375eee8c5dc7e16d24ac2d6bc1fd07166e7ae0c1eda1b9e7dd093d667ec397539fef9fffa6b4 gnash-0.8.10-giflib5.patch"
diff --git a/unmaintained/gnash/aslr-fix.patch b/unmaintained/gnash/aslr-fix.patch
new file mode 100644
index 0000000000..632443b602
--- /dev/null
+++ b/unmaintained/gnash/aslr-fix.patch
@@ -0,0 +1,52 @@
+diff -Naur gnash-0.8.10.alt/libbase/jemalloc.c gnash-0.8.10/libbase/jemalloc.c
+--- gnash-0.8.10.alt/libbase/jemalloc.c 2012-02-07 09:39:41.000000000 +0100
++++ gnash-0.8.10/libbase/jemalloc.c 2012-02-24 18:36:47.000000000 +0100
+@@ -429,7 +429,7 @@
+ static const bool __isthreaded = true;
+ #endif
+
+-#if defined(MOZ_MEMORY_SOLARIS) && defined(MAP_ALIGN) && !defined(JEMALLOC_NEVER_USES_MAP_ALIGN)
++#if defined(MOZ_MEMORY_SOLARIS) && defined(MAP_ALIGN) && !defined(JEMALLOC_NEVER_USES_MAP_ALIGN) || defined(MOZ_MEMORY_LINUX)
+ #define JEMALLOC_USES_MAP_ALIGN /* Required on Solaris 10. Might improve performance elsewhere. */
+ #endif
+
+@@ -2238,6 +2238,7 @@
+ * We don't use MAP_FIXED here, because it can cause the *replacement*
+ * of existing mappings, and we only want to create new mappings.
+ */
++#ifndef MOZ_MEMORY_LINUX
+ #ifdef MALLOC_PAGEFILE
+ if (pfd != -1) {
+ ret = mmap((void *)alignment, size, PROT_READ | PROT_WRITE, MAP_PRIVATE |
+@@ -2252,6 +2253,31 @@
+
+ if (ret == MAP_FAILED)
+ ret = NULL;
++#else /* MOZ_MEMORY_LINUX */
++#ifdef MALLOC_PAGEFILE
++ if (pfd != -1) {
++ ret = mmap((void *)alignment, size, PROT_READ | PROT_WRITE, MAP_PRIVATE |
++ MAP_NOSYNC, pfd, 0);
++ } else
++#endif
++ {
++ ret = mmap(NULL, size + alignment, PROT_READ | PROT_WRITE, MAP_PRIVATE |
++ MAP_NOSYNC | MAP_ANON, -1, 0);
++ }
++ assert(ret != NULL);
++
++ if (ret == MAP_FAILED)
++ return NULL;
++
++ uintptr_t aligned_ret;
++ size_t extra_size;
++ aligned_ret = (uintptr_t)ret + alignment - 1;
++ aligned_ret &= ~(alignment - 1);
++ extra_size = aligned_ret - (uintptr_t)ret;
++ munmap(ret, extra_size);
++ munmap(ret + extra_size + size, alignment - extra_size);
++ ret = (void*)aligned_ret;
++#endif /* ifndef MOZ_MEMORY_LINUX*/
+ return (ret);
+ }
+ #endif
diff --git a/unmaintained/gnash/gnash-0.8.10-giflib5.patch b/unmaintained/gnash/gnash-0.8.10-giflib5.patch
new file mode 100644
index 0000000000..2ca7032bb1
--- /dev/null
+++ b/unmaintained/gnash/gnash-0.8.10-giflib5.patch
@@ -0,0 +1,12 @@
+diff -rupN a/libbase/GnashImageGif.cpp b/libbase/GnashImageGif.cpp
+--- a/libbase/GnashImageGif.cpp 2012-01-19 19:17:48.000000000 +0000
++++ b/libbase/GnashImageGif.cpp 2013-07-30 09:08:37.707930583 +0000
+@@ -269,7 +269,7 @@ GifInput::processRecord(GifRecordType re
+ void
+ GifInput::read()
+ {
+- _gif = DGifOpen(_inStream.get(), &readData);
++ _gif = DGifOpen(_inStream.get(), &readData, NULL);
+
+ GifRecordType record;
+
diff --git a/unmaintained/gnash/gnash-ffmpeg.patch b/unmaintained/gnash/gnash-ffmpeg.patch
new file mode 100644
index 0000000000..dc78e81c59
--- /dev/null
+++ b/unmaintained/gnash/gnash-ffmpeg.patch
@@ -0,0 +1,24 @@
+--- gnash-0.8.9.orig/libmedia/ffmpeg/MediaParserFfmpeg.cpp
++++ gnash-0.8.9/libmedia/ffmpeg/MediaParserFfmpeg.cpp
+@@ -52,8 +52,8 @@
+ return p->readPacket(buf, buf_size);
+ }
+
+-boost::int64_t
+-MediaParserFfmpeg::seekMediaWrapper(void *opaque, boost::int64_t offset, int whence)
++::int64_t
++MediaParserFfmpeg::seekMediaWrapper(void *opaque, ::int64_t offset, int whence)
+ {
+ MediaParserFfmpeg* p = static_cast<MediaParserFfmpeg*>(opaque);
+ return p->seekMedia(offset, whence);
+--- gnash-0.8.9.orig/libmedia/ffmpeg/MediaParserFfmpeg.h
++++ gnash-0.8.9/libmedia/ffmpeg/MediaParserFfmpeg.h
+@@ -126,7 +126,7 @@
+ boost::int64_t seekMedia(boost::int64_t offset, int whence);
+
+ /// ffmpeg callback function
+- static boost::int64_t seekMediaWrapper(void *opaque, boost::int64_t offset, int whence);
++ static int64_t seekMediaWrapper(void *opaque, int64_t offset, int whence);
+
+ /// Read some of the input to figure an AVInputFormat
+ AVInputFormat* probeStream();