diff options
author | tron <tron@pkgsrc.org> | 2008-03-18 15:05:03 +0000 |
---|---|---|
committer | tron <tron@pkgsrc.org> | 2008-03-18 15:05:03 +0000 |
commit | a8b4a5440065361cf29c766730b7de4011045928 (patch) | |
tree | 0009684bc675b7101b537b6c2bef19022290e808 /multimedia | |
parent | ccfcbebab6ac3aebc78e262235218a1c7d3d2d73 (diff) | |
download | pkgsrc-a8b4a5440065361cf29c766730b7de4011045928.tar.gz |
Fix build under Mac OS X Intel by stripping out the "-fno-common" that
"yasm" doesn't understand. Also improve the similar hack used under
NetBSD to strip out "-fpic".
Diffstat (limited to 'multimedia')
-rw-r--r-- | multimedia/x264-devel/Makefile | 8 | ||||
-rw-r--r-- | multimedia/x264-devel/distinfo | 5 | ||||
-rwxr-xr-x | multimedia/x264-devel/files/strip_fopt.sh | 23 | ||||
-rw-r--r-- | multimedia/x264-devel/patches/patch-ab | 4 | ||||
-rw-r--r-- | multimedia/x264-devel/patches/patch-ac | 22 |
5 files changed, 34 insertions, 28 deletions
diff --git a/multimedia/x264-devel/Makefile b/multimedia/x264-devel/Makefile index f4bf23b2332..a221a04d9a0 100644 --- a/multimedia/x264-devel/Makefile +++ b/multimedia/x264-devel/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.9 2008/03/11 13:20:29 tron Exp $ +# $NetBSD: Makefile,v 1.10 2008/03/18 15:05:03 tron Exp $ # SNAPSHOT_DATE= 20071218 @@ -35,8 +35,14 @@ USE_LIBTOOL= yes HAS_CONFIGURE= yes CONFIGURE_ARGS+= --prefix=${PREFIX:Q} +MAKE_ENV+= SH=${SH:Q} BUILD_TARGET= default +post-extract: + ${SED} -e 's,@SH@,${SH},' ${FILESDIR}/strip_fopt.sh \ + >${WRKSRC}/strip_fopt.sh + ${CHMOD} +x ${WRKSRC}/strip_fopt.sh + .include "../../mk/pthread.buildlink3.mk" .include "../../mk/bsd.pkg.mk" diff --git a/multimedia/x264-devel/distinfo b/multimedia/x264-devel/distinfo index 2fbdb105e7e..8279074e611 100644 --- a/multimedia/x264-devel/distinfo +++ b/multimedia/x264-devel/distinfo @@ -1,8 +1,7 @@ -$NetBSD: distinfo,v 1.7 2008/03/11 13:20:29 tron Exp $ +$NetBSD: distinfo,v 1.8 2008/03/18 15:05:03 tron Exp $ SHA1 (x264-snapshot-20071218-2245.tar.bz2) = b5bc182070e17a8470618bae776488514b67a96a RMD160 (x264-snapshot-20071218-2245.tar.bz2) = 753ab79398bf5bb92b41656ef48ab57dcc63f347 Size (x264-snapshot-20071218-2245.tar.bz2) = 537622 bytes SHA1 (patch-aa) = cce1ef8b7a332e9f9a4c18a8a4246b9382dc4bca -SHA1 (patch-ab) = e4ce859a2c395e81bb2c5de3a5943c600e3c86eb -SHA1 (patch-ac) = 18a21816bddc28b9cd9139c3fdb179ebcbf03a4a +SHA1 (patch-ab) = 60de00034a4cc19aba4a2669eaf91080a5b5b6ac diff --git a/multimedia/x264-devel/files/strip_fopt.sh b/multimedia/x264-devel/files/strip_fopt.sh new file mode 100755 index 00000000000..870a5d861db --- /dev/null +++ b/multimedia/x264-devel/files/strip_fopt.sh @@ -0,0 +1,23 @@ +#!@SH@ +# +# $NetBSD: strip_fopt.sh,v 1.1 2008/03/18 15:05:04 tron Exp $ +# +# libtool assumes that the compiler can handle the -fPIC flag and the +# -fno-common. This isn't always true, for example yasm can't handle it. +command="$1" +shift +while [ $# -gt 0 ]; do + case "$1" in + -fPIC|-fno-common) + ;; + -DPIC) + command="$command -D__PIC__" + ;; + *) + command="$command $1" + ;; + esac + shift +done +echo $command +exec $command diff --git a/multimedia/x264-devel/patches/patch-ab b/multimedia/x264-devel/patches/patch-ab index a4888f90e34..ccdf302033a 100644 --- a/multimedia/x264-devel/patches/patch-ab +++ b/multimedia/x264-devel/patches/patch-ab @@ -1,4 +1,4 @@ -$NetBSD: patch-ab,v 1.4 2008/03/11 13:20:29 tron Exp $ +$NetBSD: patch-ab,v 1.5 2008/03/18 15:05:04 tron Exp $ --- Makefile.orig 2007-12-18 22:45:04.000000000 +0100 +++ Makefile @@ -78,7 +78,7 @@ $NetBSD: patch-ab,v 1.4 2008/03/11 13:20:29 tron Exp $ +common/amd64/*.lo: common/amd64/amd64inc.asm +common/i386/*.lo: common/i386/i386inc.asm +%.lo: %.asm -+ ${LIBTOOL} --mode=compile --tag=ASM sh strip_fPIC.sh $(AS) $(ASFLAGS) -o $@ $< ++ ${LIBTOOL} --mode=compile --tag=ASM ./strip_fopt.sh $(AS) $(ASFLAGS) -o $@ $< # delete local/anonymous symbols, so they don't show up in oprofile -@ strip -x $@ diff --git a/multimedia/x264-devel/patches/patch-ac b/multimedia/x264-devel/patches/patch-ac deleted file mode 100644 index 5688d7ed192..00000000000 --- a/multimedia/x264-devel/patches/patch-ac +++ /dev/null @@ -1,22 +0,0 @@ -$NetBSD: patch-ac,v 1.1 2008/03/10 11:59:26 drochner Exp $ - ---- strip_fPIC.sh.orig 2008-01-11 20:38:05.000000000 +0100 -+++ strip_fPIC.sh -@@ -0,0 +1,17 @@ -+#!/bin/sh -+# -+# libtool assumes that the compiler can handle the -fPIC flag -+# This isn't always true (for example, nasm can't handle it) -+command="" -+while [ $1 ]; do -+ if [ "$1" != "-fPIC" ]; then -+ if [ "$1" = "-DPIC" ]; then -+ command="$command -D__PIC__" -+ else -+ command="$command $1" -+ fi -+ fi -+ shift -+done -+echo $command -+exec $command |