[kde-freebsd] [PATCH] OPTIONS'ify kdelibs3

Doug Barton dougb at freebsd.org
Thu Sep 20 08:22:22 CEST 2007

>Submitter-Id:	current-users
>Originator:	Doug Barton
>Organization:	AAAG
>Confidential:	no
>Synopsis:	[PATCH] OPTIONS'ify kdelibs3
>Severity:	non-critical
>Priority:	low
>Category:	ports
>Class:		change-request
>Release:	FreeBSD 7.0-CURRENT-0918 i386
	Currently kdelibs3 depends unconditionally on kerberos, which
	is a problem since don't have that installed. The patch below
	adds OPTIONS to the Makefile for kdelibs3 for kerberos, libthai,
	and CUPS.

	I used to patch the Makefile by hand so I know that KDE runs
	fine without kerberos. I am running the new build without
	libthai right now, so far so good.

	The CUPS stuff I just relocated, so I imagine that should be

	I tried to preserve the status quo with the defaults, but I
	think it would probably make more sense if libthai defaulted
	to off. I also have no objections to changing the specifics
	of any of the rest of the patch either, it's the idea that
	I think is valuable.
	Apply the following patch:

Index: Makefile
RCS file: /usr/local/ncvs/ports/x11/kdelibs3/Makefile,v
retrieving revision 1.219
diff -u -r1.219 Makefile
--- Makefile	19 Sep 2007 16:44:36 -0000	1.219
+++ Makefile	20 Sep 2007 01:59:50 -0000
@@ -8,7 +8,7 @@
 PORTNAME=	kdelibs
 CATEGORIES=	x11 kde ipv6
@@ -26,7 +26,6 @@
 		idn:${PORTSDIR}/dns/libidn \
 		jasper:${PORTSDIR}/graphics/jasper \
 		pcre:${PORTSDIR}/devel/pcre \
-		thai:${PORTSDIR}/devel/libthai \
 		tiff.4:${PORTSDIR}/graphics/tiff \
 		xml2.5:${PORTSDIR}/textproc/libxml2 \
@@ -36,15 +35,6 @@
 CONFLICTS+=	kdeadmin-3.[0-3].* kdeadmin-3.4.[0-1]* kdeartwork-3.[2-3]* kdebase-3.[0-4]* kdepim-3.2*
-.if defined(WITHOUT_CUPS) || defined(KDE_WITHOUT_CUPS)
-CONFLICTS+=	kdelibs-[0-9]*
-PLIST=		${.CURDIR}/../kdelibs3-nocups/pkg-plist
-CONFLICTS+=	kdelibs-nocups-[0-9]*
-LIB_DEPENDS+=	cups:${PORTSDIR}/print/cups-base
 USE_BZIP2=	yes
 USE_FAM=	yes
@@ -63,7 +53,6 @@
 		--enable-mt \
 		--build=${MACHINE_ARCH}-portbld-freebsd${OSREL} \
 		--x-libraries=${X11BASE}/lib --x-includes=${X11BASE}/include \
-		--with-libthai=yes \
 		--with-lua=no \
 CONFIGURE_ENV+=	libltdl_cv_shlibext=".so"
@@ -71,9 +60,37 @@
 FONTSCALE=	${X11BASE}/lib/X11/fonts/TTF/luximb.ttf
 FONTENCOD=	${X11BASE}/lib/X11/fonts/encodings/encodings.dir
+OPTIONS=	KDELIBS_KERBEROS "Include kerberos support" on \
+		CUPS	"Support for the Common Unix Print Server" on \
+		LIBTHAI "Thai-language support from libthai" off
 .include "${.CURDIR}/../../x11/kde3/Makefile.kde"
 .include <bsd.port.pre.mk>
+# Handle OPTIONS
+CONFIGURE_ARGS+=	--with-gssapi
+CONFIGURE_ARGS+=	--without-gssapi
+.if defined(WITHOUT_CUPS) || defined(KDE_WITHOUT_CUPS)
+CONFLICTS+=	kdelibs-[0-9]*
+PLIST=		${.CURDIR}/../kdelibs3-nocups/pkg-plist
+CONFLICTS+=	kdelibs-nocups-[0-9]*
+LIB_DEPENDS+=	cups:${PORTSDIR}/print/cups-base
+.if !defined(WITHOUT_LIBTHAI)
+CONFIGURE_ARGS+=	--with-libthai=yes
+LIB_DEPENDS+=		thai:${PORTSDIR}/devel/libthai
+CONFIGURE_ARGS+=	--without-libthai
 # bzip2 is required as a libdepend for the help: kioslave
 .if !exists(/usr/bin/bzip2)
 LIB_DEPENDS+=	bz2.1:${PORTSDIR}/archivers/bzip2

More information about the kde-freebsd mailing list