On 2014/01/10 19:13, Brad Smith wrote: > Here is a diff to have MPlayer build using Clang to take advantage > of the integrated assembler to be able to build the SSSE3 / SSE4 > support. > > Note: has not been checked on i386, please someone try building this > and see if it does. *crosses fingers*
It builds on i386 with the following diff (which hacks out the configure test), but it's on a remote machine so I can't test runtime. (Note that -fomit-frame-pointer is still needed even though afaik clang is not doing pie by default). i386 package at http://junkpile.org/mplayer-20130819p2.tgz if anyone would like to test it without having to build. Index: Makefile =================================================================== RCS file: /cvs/ports/x11/mplayer/Makefile,v retrieving revision 1.231 diff -u -p -r1.231 Makefile --- Makefile 10 Jan 2014 21:52:29 -0000 1.231 +++ Makefile 11 Jan 2014 12:01:38 -0000 @@ -15,6 +15,7 @@ SUBST_VARS += PREFIX CONFDIR # Distfiles must be hand-rolled, see README N = mplayer DISTNAME = mplayer-${V} +REVISION = 0 EXTRACT_SUFX = .tar.xz CATEGORIES = x11 multimedia @@ -37,7 +38,8 @@ MASTER_SITES = http://comstyle.com/sourc MAINTAINER = Edd Barrett <[email protected]> -MODULES += converters/libiconv +MODULES += converters/libiconv \ + lang/clang LIB_DEPENDS = graphics/png \ graphics/jpeg \ @@ -71,6 +73,9 @@ BUILD_DEPENDS +=graphics/ffmpeg:patch BUILD_DEPENDS += devel/yasm .endif +MODCLANG_ARCHS= amd64 i386 +MODCLANG_LANGS= c + CONFDIR = ${SYSCONFDIR}/mplayer .if ${MACHINE_ARCH:Marm} @@ -164,11 +169,8 @@ WANTLIB += vorbisenc vorbis CONFIGURE_ENV += LOCALBASE="${LOCALBASE}" TMPDIR="${WRKBUILD}" -# binutils 2.15 does not support SSSE3 / SSE4 for amd64 / i386 .if ${MACHINE_ARCH:Mamd64} || ${MACHINE_ARCH:Mi386} CONFIGURE_ARGS += --enable-runtime-cpudetection -CONFIGURE_ARGS += --disable-ssse3 -CONFIGURE_ARGS += --disable-sse4 .endif # binutils 2.15 assembler missing opcode support Index: patches/patch-configure =================================================================== RCS file: /cvs/ports/x11/mplayer/patches/patch-configure,v retrieving revision 1.73 diff -u -p -r1.73 patch-configure --- patches/patch-configure 10 Jan 2014 21:52:29 -0000 1.73 +++ patches/patch-configure 11 Jan 2014 13:35:10 -0000 @@ -1,6 +1,6 @@ $OpenBSD: patch-configure,v 1.73 2014/01/10 21:52:29 brad Exp $ ---- configure.orig Mon Jan 6 17:03:04 2014 -+++ configure Mon Jan 6 17:22:43 2014 +--- configure.orig Mon Jan 6 15:03:04 2014 ++++ configure Sat Jan 11 05:08:34 2014 @@ -1497,36 +1497,36 @@ echo configuration: $configuration > "$TMPLOG" echo >> "$TMPLOG" @@ -85,6 +85,15 @@ $OpenBSD: patch-configure,v 1.73 2014/01 extern_prefix=${sym%%ff_extern*} def_extern_asm="#define EXTERN_ASM $extern_prefix" def_extern_prefix="#define EXTERN_PREFIX \"$extern_prefix\"" +@@ -2820,7 +2820,7 @@ elif test $relocatable = "yes" ; then + fi + echores $relocatable + +-if x86_32 ; then ++if 0; then # x86_32 + # Checking assembler (_as) compatibility... + # Added workaround for older as that reads from stdin by default - atmos + as_version=$(echo '' | $_as -version 2>&1 | sed -n 's/^.*assembler \(version \)*\([0-9.]*\).*$/\2/p') @@ -6153,7 +6153,7 @@ echocheck "cdparanoia" if test "$_cdparanoia" = auto ; then _cdparanoia=no
