Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 28 Jan 2013 15:24:55 +0700 (NOVT)
From:      Alexey Dokuchaev <danfe@regency.nsu.ru>
To:        FreeBSD-gnats-submit@freebsd.org
Subject:   ports/175644: www/qt4-webkit: OPTIONize dependency on GStreamer
Message-ID:  <201301280824.r0S8OtSi006716@regency.nsu.ru>
Resent-Message-ID: <201301280830.r0S8U1ku005261@freefall.freebsd.org>

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

>Number:         175644
>Category:       ports
>Synopsis:       www/qt4-webkit: OPTIONize dependency on GStreamer
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Mon Jan 28 08:30:00 UTC 2013
>Closed-Date:
>Last-Modified:
>Originator:     Alexey Dokuchaev
>Release:        FreeBSD 8.3-STABLE i386
>Organization:
>Environment:
>Description:
I've noticed that www/qt4-webkit port unconditionally sets USE_GSTREAMER=yes,
while IMHO it should be optional.  For example, Gentoo Linux allows to
disable it:

http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/x11-libs/qt-webkit/qt-webkit-4.8.4.ebuild

It seems that Gentoo folks pass -DENABLE_VIDEO=0 to enforce it, but grepping
qt4-webkit-4.8.2.log shows that this macro is already set to zero (on command
line) even with USE_GSTREAMER=yes.  Someone with a clue should take a look
what's going on here...

Anyhow, I've OPTIONized the www/qt4-webkit, see the patch.

Perhaps it makes sense to integrate it with devel/qt4/files/Makefile.options
instead of OPTIONS_DEFINE in www/qt4-webkit, but right now it looks like this
file is to synchronize QCONFIG_FLAGS between qt4-corelib and qt4-gui, and I'm
not sure if www/qt4-webkit fits this.  I'll leave it at kde@ team discretion.

I just want to keep my systems GStreamer-free.  :-)

I've also reindented comments, otherwise they will be parsed by shell, not
by make.
>How-To-Repeat:
>Fix:
Index: Makefile
===================================================================
--- Makefile	(revision 310911)
+++ Makefile	(working copy)
@@ -10,7 +10,6 @@
 COMMENT=	Qt4 WebKit engine
 
 USE_GNOME=	glib20
-USE_GSTREAMER=	yes
 USE_QT4=	corelib declarative gui network \
 		qmake_build moc_build rcc_build
 QT_NONSTANDARD=	yes
@@ -44,8 +43,19 @@
 
 EXTRA_PATCHES=	${.CURDIR}/../../devel/qt4/files/patch-configure
 
+OPTIONS_DEFINE=	GSTREAMER
+OPTIONS_DEFAULT=	GSTREAMER
+
+GSTREAMER_DESC=	HTML5 audio and video support
+
 .include <bsd.port.pre.mk>
 
+.if ${PORT_OPTIONS:MGSTREAMER}
+USE_GSTREAMER=	yes
+.else
+CONFIGURE_ARGS+=	-no-gstreamer
+.endif
+
 # Base ld(1) segfaults on PowerPC:
 # http://bugs.freebsd.org/173042
 .if ${ARCH} == "powerpc"
@@ -57,8 +67,7 @@
 	${LN} -sf ${LOCALBASE}/bin/qmake-qt4 ${WRKSRC}/bin/qmake
 	${LN} -sf ${LOCALBASE}/bin/moc-qt4 ${WRKSRC}/bin/moc
 	${LN} -sf ${LOCALBASE}/bin/rcc ${WRKSRC}/bin/rcc
-	# Avoid building and installing several tests. Should this be
-	# made an option?
+# Avoid building and installing several tests. Should this be made an option?
 	${REINPLACE_CMD} -e '/WebKit\/qt\/tests/ d' \
 		${BUILD_WRKSRC}/WebKit.pro
 
@@ -76,7 +85,7 @@
 	${REINPLACE_CMD} -E -e 's|-L.[^[:space:]]*qt-x11-opensource.[^[:space:]]*lib||g' \
 			-E -e 's|(.*location=).*moc|\1${PREFIX}/bin/moc-qt4|g' \
 		${WRKSRC}/lib/pkgconfig/QtWebKit.pc
-	# QtWebKit is statically linked with jscore, remove the latest.
+# QtWebKit is statically linked with jscore, remove the latest.
 	${REINPLACE_CMD} -e 's|-L../JavaScriptCore/release||; s|-ljscore||' \
 		${WRKSRC}/lib/pkgconfig/QtWebKit.pc \
 		${WRKSRC}/lib/libQtWebKit.la
>Release-Note:
>Audit-Trail:
>Unformatted:



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