summaryrefslogtreecommitdiff
path: root/multimedia
diff options
context:
space:
mode:
authortsutsui <tsutsui>2010-08-12 15:28:46 +0000
committertsutsui <tsutsui>2010-08-12 15:28:46 +0000
commit8db102c0a025c5e74c8c0296e64d4bb7328c0919 (patch)
tree085e5b5b7b8fc92d5e44c5f0abb81dc2b55ecd22 /multimedia
parentae4110627ea2ddae4471e27663821cfb3cb45653 (diff)
downloadpkgsrc-8db102c0a025c5e74c8c0296e64d4bb7328c0919.tar.gz
Fix build failure and make mplayer work properly on NetBSD/arm:
- workaround name conflict with system header <arm/bswap.h> in libavutils by subst.mk replacement - explicitly disable armv5te, armv6, and armv6t2 options that are enabled by autodetect code in configure but cause illegal instruction errors on StrongARM and XScale machines Tested on NetBSD/hpcarm (WS011SH) and NetBSD/shark (Funai's DNARD) 5.99.38.
Diffstat (limited to 'multimedia')
-rw-r--r--multimedia/mplayer-share/Makefile.common17
1 files changed, 16 insertions, 1 deletions
diff --git a/multimedia/mplayer-share/Makefile.common b/multimedia/mplayer-share/Makefile.common
index 0b3af52499a..1d96c25346b 100644
--- a/multimedia/mplayer-share/Makefile.common
+++ b/multimedia/mplayer-share/Makefile.common
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.common,v 1.44 2010/01/03 23:42:44 ahoka Exp $
+# $NetBSD: Makefile.common,v 1.45 2010/08/12 15:28:46 tsutsui Exp $
# used by multimedia/gmplayer/Makefile
# used by multimedia/mencoder/Makefile
# used by multimedia/mplayer/Makefile
@@ -61,4 +61,19 @@ CONFIGURE_ENV+= TMPDIR=${WRKDIR:Q}
CONFIGURE_ARGS+= --enable-big-endian
.endif
+.if !empty(MACHINE_PLATFORM:MNetBSD-*-arm)
+# Avoid crash with system include file:
+pre-patch:
+ mv ${WRKSRC}/libavutil/arm/bswap.h ${WRKSRC}/libavutil/arm/avbswap.h
+
+SUBST_CLASSES+= arm_bswap
+SUBST_STAGE.arm_bswap= pre-configure
+SUBST_FILES.arm_bswap= libavutil/bswap.h
+SUBST_SED.arm_bswap= -e s,\"arm/bswap.h\",\"arm/avbswap.h\",g
+SUBST_MESSAGE.arm_bswap= Fixing "arm/bswap.h" conflict in libavutil
+
+# autodetect code enables these options on NetBSD/arm but it should not
+CONFIGURE_ARGS+= --disable-armv5te --disable-armv6 --disable-armv6t2
+.endif
+
.include "../../multimedia/mplayer-share/options.mk"