summaryrefslogtreecommitdiff
path: root/multimedia/mjpegtools
diff options
context:
space:
mode:
authordsomero <xgizzmo@slackbuilds.org>2010-05-19 01:54:56 -0400
committerdsomero <xgizzmo@slackbuilds.org>2010-05-19 01:54:56 -0400
commitf10a7e233e067ae39596ffe0b411befd8c3ac620 (patch)
tree641e003788d37ce0d3402533beb738d853ec66a6 /multimedia/mjpegtools
parent49e6340cd8b5eafa0621caca6c962fecba7f5a39 (diff)
downloadslackbuilds-f10a7e233e067ae39596ffe0b411befd8c3ac620.tar.gz
multimedia/mjpegtools: Patched to build with glibc 2.10.
Diffstat (limited to 'multimedia/mjpegtools')
-rw-r--r--multimedia/mjpegtools/mjpegtools-1.9.0-glibc-2.10.patch11
-rw-r--r--multimedia/mjpegtools/mjpegtools-1.9.0-jpeg-7.patch24
-rw-r--r--multimedia/mjpegtools/mjpegtools.SlackBuild10
3 files changed, 39 insertions, 6 deletions
diff --git a/multimedia/mjpegtools/mjpegtools-1.9.0-glibc-2.10.patch b/multimedia/mjpegtools/mjpegtools-1.9.0-glibc-2.10.patch
new file mode 100644
index 0000000000..e161560468
--- /dev/null
+++ b/multimedia/mjpegtools/mjpegtools-1.9.0-glibc-2.10.patch
@@ -0,0 +1,11 @@
+--- mjpegtools-1.9.0/mplex/lpcmstrm_in.cpp.orig 2009-05-27 01:31:46.000000000 -0700
++++ mjpegtools-1.9.0/mplex/lpcmstrm_in.cpp 2009-05-27 01:33:09.000000000 -0700
+@@ -53,7 +53,7 @@
+
+ bool LPCMStream::Probe(IBitStream &bs )
+ {
+- char *last_dot = strrchr( bs.StreamName(), '.' );
++ const char *last_dot = strrchr( bs.StreamName(), '.' );
+ return
+ last_dot != NULL
+ && strcmp( last_dot+1, "lpcm") == 0;
diff --git a/multimedia/mjpegtools/mjpegtools-1.9.0-jpeg-7.patch b/multimedia/mjpegtools/mjpegtools-1.9.0-jpeg-7.patch
new file mode 100644
index 0000000000..ec36731862
--- /dev/null
+++ b/multimedia/mjpegtools/mjpegtools-1.9.0-jpeg-7.patch
@@ -0,0 +1,24 @@
+Fix segmentation fault with jpeg-7 and above where dinfo.do_fancy_upsampling isn't set by default to FALSE anymore.
+
+Patch by: Salah Coronya
+
+http://bugs.gentoo.org/show_bug.cgi?id=293919
+
+--- lavtools/jpegutils.c
++++ lavtools/jpegutils.c
+@@ -502,6 +502,7 @@
+
+ jpeg_read_header (&dinfo, TRUE);
+ dinfo.raw_data_out = TRUE;
++ dinfo.do_fancy_upsampling = FALSE;
+ dinfo.out_color_space = JCS_YCbCr;
+ dinfo.dct_method = JDCT_IFAST;
+ guarantee_huff_tables(&dinfo);
+@@ -599,6 +600,7 @@
+ if (field > 0) {
+ jpeg_read_header (&dinfo, TRUE);
+ dinfo.raw_data_out = TRUE;
++ dinfo.do_fancy_upsampling = FALSE;
+ dinfo.out_color_space = JCS_YCbCr;
+ dinfo.dct_method = JDCT_IFAST;
+ jpeg_start_decompress (&dinfo);
diff --git a/multimedia/mjpegtools/mjpegtools.SlackBuild b/multimedia/mjpegtools/mjpegtools.SlackBuild
index e7397670d2..86d7b3e879 100644
--- a/multimedia/mjpegtools/mjpegtools.SlackBuild
+++ b/multimedia/mjpegtools/mjpegtools.SlackBuild
@@ -57,6 +57,8 @@ chmod -R a-s,u+w,go+r-w .
# Fix for x86_64
sed -i -e '/ARCHFLAGS=/s:=.*:=:' configure
+patch -p1 < $CWD/mjpegtools-1.9.0-glibc-2.10.patch
+patch -p0 < $CWD/mjpegtools-1.9.0-jpeg-7.patch
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
@@ -74,12 +76,8 @@ CXXFLAGS="$SLKCFLAGS" \
make
make install DESTDIR=$PKG
-( cd $PKG
- find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | \
- xargs strip --strip-unneeded 2> /dev/null || true
- find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | \
- xargs strip --strip-unneeded 2> /dev/null
-)
+find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \
+ | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
( cd $PKG/usr/man
find . -type f -exec gzip -9 {} \;