Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 18 Jan 2005 09:55:57 +0100
From:      Jeremie Le Hen <jeremie@le-hen.org>
To:        freebsd-ports@freebsd.org
Cc:        jeremie@le-hen.org
Subject:   WITHOUT_X11 knob for mplayer
Message-ID:  <20050118085557.GP36629@obiwan.tataz.chchile.org>

next in thread | raw e-mail | index | archive | help

--b5gNqxB1S1yM7hjW
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

Hi,

I'm using mplayer as an MP3 mplayer on a small computer on which I don't
want to install any graphical interface.  Thus I added the WITHOUT_X11
knob for the mplayer port.  The patch is attached.  Note that I added
an explicit dependency on imake in this case since mplayer requires it
to build.

Does this make sense to you to have this knob ?  I don't think it's a
great deal anyway, the default behaviour stays unchanged.  Should I
submit a PR for this (and get it lost for months ;-) ) ?

Thanks.
Regards,

PS: If you prefer using your web browser, use:
http://jeremie.le-hen.org/~tataz/mplayer.WITHOUT_X11.patch
-- 
Jeremie Le Hen
jeremie@le-hen.org

--b5gNqxB1S1yM7hjW
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="mplayer.WITHOUT_X11.patch"

Index: Makefile
===================================================================
RCS file: /home/ncvs/ports/multimedia/mplayer/Makefile,v
retrieving revision 1.110
diff -u -r1.110 Makefile
--- Makefile	13 Jan 2005 19:04:06 -0000	1.110
+++ Makefile	16 Jan 2005 23:01:14 -0000
@@ -38,6 +38,11 @@
 # the default is to build mplayer with mencoder. If you're sure that you
 # don't want to encode or recode any media file, then define this.
 #
+# WITHOUT_X11
+# default: undefined
+# the default is to build mplayer with X11 support.  If you don't want to
+# install any X11 environnement, this one is for you.
+#
 # WITH_GTK1|WITH_GTK2
 # default: autodetect GTK1
 # if you want mplayer to have gui abilities, you can use this knob to define
@@ -269,15 +274,12 @@
 USE_BZIP2=	yes
 USE_GMAKE=	yes
 USE_ICONV=	yes
-USE_XLIB=	yes
 GNU_CONFIGURE=	yes
 CONFIGURE_ENV=	PTHREAD_CFLAGS="${PTHREAD_CFLAGS}" \
 		PTHREAD_LIBS=${PTHREAD_LIBS} \
 		TMPDIR="${WRKSRC}"
 CONFIGURE_ARGS=	--with-extralibdir=${LOCALBASE}/lib \
 		--with-extraincdir=${LOCALBASE}/include \
-		--with-x11libdir=${X11BASE}/lib \
-		--with-x11incdir=${X11BASE}/include \
 		--enable-png \
 		--enable-menu \
 		--disable-libfame \
@@ -285,6 +287,16 @@
 		--disable-tv-v4l \
 		--disable-tremor
 
+.if defined(WITHOUT_X11)
+WITHOUT_GUI=	yes
+BUILD_DEPENDS+=	imake:${PORTSDIR}/devel/imake-6
+.else
+USE_XLIB=	yes
+CONFIGURE_ARGS+=--with-x11libdir=${X11BASE}/lib \
+		--with-x11incdir=${X11BASE}/include
+.endif
+
+
 .if defined(WITH_LANG)
 CONFIGURE_ARGS+=--language=${WITH_LANG}
 .endif

--b5gNqxB1S1yM7hjW--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050118085557.GP36629>