diff options
author | riggs <riggs@FreeBSD.org> | 2015-04-12 22:37:50 +0800 |
---|---|---|
committer | riggs <riggs@FreeBSD.org> | 2015-04-12 22:37:50 +0800 |
commit | 4f611b7c6dfd6a51c2f78c40371c0f4bc366d4b3 (patch) | |
tree | d48e9dcc7f426b913c4b380ec22f9c763b931b99 /multimedia | |
parent | 73cebd91d566599df3cd98ef642bb7e68570dfdf (diff) | |
download | freebsd-ports-gnome-4f611b7c6dfd6a51c2f78c40371c0f4bc366d4b3.tar.gz freebsd-ports-gnome-4f611b7c6dfd6a51c2f78c40371c0f4bc366d4b3.tar.zst freebsd-ports-gnome-4f611b7c6dfd6a51c2f78c40371c0f4bc366d4b3.zip |
Fix runtime crash with certain MPEG2 files on pre-10 systems.
PR: 199283
MFH: 2015Q2
Diffstat (limited to 'multimedia')
-rw-r--r-- | multimedia/mencoder/Makefile | 1 | ||||
-rw-r--r-- | multimedia/mplayer/Makefile | 1 | ||||
-rw-r--r-- | multimedia/mplayer/Makefile.options | 5 | ||||
-rw-r--r-- | multimedia/mplayer/files/extra-patch-aligned_alloc | 27 | ||||
-rw-r--r-- | multimedia/mplayer/files/patch-configure | 24 |
5 files changed, 34 insertions, 24 deletions
diff --git a/multimedia/mencoder/Makefile b/multimedia/mencoder/Makefile index 4a8f7560a176..65c5bd6f6c36 100644 --- a/multimedia/mencoder/Makefile +++ b/multimedia/mencoder/Makefile @@ -3,6 +3,7 @@ PORTNAME= mencoder PORTVERSION= ${MPLAYER_PORT_VERSION} +PORTREVISION= 1 COMMENT= Convenient video file and movie encoder diff --git a/multimedia/mplayer/Makefile b/multimedia/mplayer/Makefile index fbaeef3c3bba..5725c87ff2a2 100644 --- a/multimedia/mplayer/Makefile +++ b/multimedia/mplayer/Makefile @@ -3,6 +3,7 @@ PORTNAME= mplayer PORTVERSION= ${MPLAYER_PORT_VERSION} +PORTREVISION= 1 COMMENT= High performance media player supporting many formats diff --git a/multimedia/mplayer/Makefile.options b/multimedia/mplayer/Makefile.options index 49087d7e0938..5a8b381f0b0c 100644 --- a/multimedia/mplayer/Makefile.options +++ b/multimedia/mplayer/Makefile.options @@ -84,6 +84,11 @@ CONFIGURE_ARGS+= --disable-tv-v4l1 \ # Build system handling (including OPTIONS) # ========================================= +# Support for aligned_alloc +.if ${OSVERSION} >= 1000000 +EXTRA_PATCHES+= ${FILESDIR}/extra-patch-aligned_alloc +.endif + # Supported architectures for runtime CPU detection .if ${ARCH} == "amd64" || ${ARCH} == "i386" || ${ARCH} == "ppc" MPLAYER_RTCPU_SUPPORTED_ARCH= yes diff --git a/multimedia/mplayer/files/extra-patch-aligned_alloc b/multimedia/mplayer/files/extra-patch-aligned_alloc new file mode 100644 index 000000000000..8d50f1958505 --- /dev/null +++ b/multimedia/mplayer/files/extra-patch-aligned_alloc @@ -0,0 +1,27 @@ +--- configure.orig 2014-12-17 22:02:44.000000000 +0100 ++++ configure 2015-03-28 13:56:41.340987552 +0100 +@@ -3798,17 +3808,17 @@ + echores "$aligned_malloc" + + +-echocheck "memalign()" ++echocheck "aligned_alloc()" + # XXX restrict to x86 ? extend to other CPUs/cacheline sizes ? +-def_memalign_hack='#define CONFIG_MEMALIGN_HACK 0' ++def_memalign='#define HAVE_MEMALIGN 0' + _memalign=no +-statement_check malloc.h 'memalign(64, sizeof(char))' && _memalign=yes ++statement_check stdlib.h 'aligned_alloc(32, 32*sizeof(char))' && _memalign=yes + if test "$_memalign" = yes ; then +- def_memalign='#define HAVE_MEMALIGN 1' ++ def_map_memalign='#define memalign(a, b) aligned_alloc(a, b)' ++ def_memalign_hack='#define CONFIG_MEMALIGN_HACK 0' + else +- def_memalign='#define HAVE_MEMALIGN 0' + def_map_memalign='#define memalign(a, b) malloc(b)' +- darwin || def_memalign_hack='#define CONFIG_MEMALIGN_HACK 1' ++ def_memalign_hack='#define CONFIG_MEMALIGN_HACK 1' + fi + echores "$_memalign" + + diff --git a/multimedia/mplayer/files/patch-configure b/multimedia/mplayer/files/patch-configure index fbebd20efe24..8bbd97b6da6f 100644 --- a/multimedia/mplayer/files/patch-configure +++ b/multimedia/mplayer/files/patch-configure @@ -62,30 +62,6 @@ echocheck "softfloat ABI" softfloat=yes cpp_condition_check '' 'defined(__ARM_PCS_VFP) || (!defined(__ARM_PCS) && !defined(__SOFTFP__))' && softfloat=no -@@ -3798,17 +3808,17 @@ - echores "$aligned_malloc" - - --echocheck "memalign()" -+echocheck "aligned_alloc()" - # XXX restrict to x86 ? extend to other CPUs/cacheline sizes ? --def_memalign_hack='#define CONFIG_MEMALIGN_HACK 0' -+def_memalign='#define HAVE_MEMALIGN 0' - _memalign=no --statement_check malloc.h 'memalign(64, sizeof(char))' && _memalign=yes -+statement_check stdlib.h 'aligned_alloc(32, 32*sizeof(char))' && _memalign=yes - if test "$_memalign" = yes ; then -- def_memalign='#define HAVE_MEMALIGN 1' -+ def_map_memalign='#define memalign(a, b) aligned_alloc(a, b)' -+ def_memalign_hack='#define CONFIG_MEMALIGN_HACK 0' - else -- def_memalign='#define HAVE_MEMALIGN 0' - def_map_memalign='#define memalign(a, b) malloc(b)' -- darwin || def_memalign_hack='#define CONFIG_MEMALIGN_HACK 1' -+ def_memalign_hack='#define CONFIG_MEMALIGN_HACK 1' - fi - echores "$_memalign" - @@ -3914,7 +3924,7 @@ if linux ; then THREAD_CFLAGS=-D_REENTRANT |