mplayer options patch

Anton Shterenlikht mexas at bristol.ac.uk
Fri Jan 7 13:32:42 UTC 2011


On Fri, Jan 07, 2011 at 03:28:44PM +0300, Anonymous wrote:
> Anton Shterenlikht <mexas at bristol.ac.uk> writes:
> 
> > On Fri, Jan 07, 2011 at 03:00:39PM +0300, Anonymous wrote:
> >> Anton Shterenlikht <mexas at bristol.ac.uk> writes:
> >> 
> >> >>   $ make config
> >> >>   "Makefile", line 16: Malformed conditional (${ARCH} == "i386" || ${ARCH} == "amd64" || ${ARCH} == "powerpc")
> >> >>   "Makefile", line 18: if-less else
> >> >>   "Makefile", line 20: if-less endif
> >> >>   make: fatal errors encountered -- cannot continue
> >> >
> >> > I put Eygene's snippet after .include <bsd.port.pre.mk>,
> >> > see my previous post. It seems to work.
> >> 
> >> bsd.port.pre.mk starts after OPTIONS were already parsed.
> >> Try to check
> >> 
> >>   $ make rmconfig
> >>   $ make -V WITH_RTCPU ARCH=sparc64
> >>   true
> >
> > # make rmconfig
> > ===> Removing user-configured options for mplayer-1.0.r20101106
> > rmdir: /var/db/ports/mplayer: Directory not empty
> > *** Error code 1 (ignored)
> > # make -V WITH_RTCPU ARCH=sparc64
> >
> > # make -V WITH_RTCPU ARCH=ia64
> >
> > # 
> 
> My bad, I forgot to remove RTCPU when added the ifdef.
> 
>   $ make -V WITH_RTCPU ARCH=sparc64
> 
>   $ make -V WITHOUT_RTCPU ARCH=sparc64
> 
>   $ make -V CONFIGURE_ARGS ARCH=sparc64 | fgrep run
>   ... --enable-runtime-cpudetection ... ${_LATE_CONFIGURE_ARGS}
> 
> It's not only for sparc64, there is no WITH/WITHOUT_RTPCU for i386.
> But the configure option still works
> 
>   .if !defined(WITHOUT_RTCPU)
>   CONFIGURE_ARGS+=--enable-runtime-cpudetection
>   .endif

I don't think I need to change any other options from 
the current default to make it build and run on my ia64.

So if this patch seems reasonable, can somebody submit it?

many thanks
anton


--- Makefile	2010-12-02 09:18:00.000000000 +0000
+++ Makefile.new	2011-01-07 11:16:56.000000000 +0000
@@ -13,7 +13,6 @@
 .include "${.CURDIR}/Makefile.shared"
 
 OPTIONS=	DEBUG "Include debug symbols in mplayer's binaries" off
-OPTIONS+=	RTCPU "Allow runtime CPU detection" on
 OPTIONS+=	OCFLAGS "Use optimized compiler flags" on
 OPTIONS+=	IPV6 "Include inet6 network support" on
 OPTIONS+=	X11 "Enable X11 support for mplayer's video output" on
@@ -75,6 +74,12 @@
 BROKEN=		Does not compile on sparc64
 .endif
 
+.if ${ARCH} == "i386" || ${ARCH} == "amd64" || ${ARCH} == "powerpc"
+OPTIONS+=       RTCPU "Allow runtime CPU detection" on
+.else
+OPTIONS+=       RTCPU "Allow runtime CPU detection" off
+.endif
+
 CONFIGURE_ARGS+=	--disable-ssse3 \
 			--disable-directfb \
 			--disable-faac \

-- 
Anton Shterenlikht
Room 2.6, Queen's Building
Mech Eng Dept
Bristol University
University Walk, Bristol BS8 1TR, UK
Tel: +44 (0)117 331 5944
Fax: +44 (0)117 929 4423


More information about the freebsd-ports mailing list