Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 12 Nov 2013 14:18:09 +0100 (CET)
From:      Mathieu Arnold <mat@FreeBSD.org>
To:        FreeBSD-gnats-submit@freebsd.org
Cc:        swills@FreeBSD.org
Subject:   ports/183893: [PATCH] emulators/open-vm-tools: Convert to new options framework
Message-ID:  <20131112131809.3AE9014269C@aragorn.in.absolight.net>
Resent-Message-ID: <201311121320.rACDK0xa031365@freefall.freebsd.org>

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

>Number:         183893
>Category:       ports
>Synopsis:       [PATCH] emulators/open-vm-tools: Convert to new options framework
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Tue Nov 12 13:20:00 UTC 2013
>Closed-Date:
>Last-Modified:
>Originator:     Mathieu Arnold
>Release:        FreeBSD 9.2-RELEASE i386
>Organization:
Absolight
>Environment:
System: FreeBSD aragorn.in.absolight.net 9.2-RELEASE FreeBSD 9.2-RELEASE #0 r255898: Fri Sep 27 03:52:52 UTC
>Description:
- Convert to new options framework
- Pet portlint

Port maintainer (swills@FreeBSD.org) is cc'd.

Generated with FreeBSD Port Tools 0.99_9 (mode: change, diff: SVN)
>How-To-Repeat:
>Fix:

--- open-vm-tools-425873_4,1.patch begins here ---
Index: open-vm-tools/Makefile
===================================================================
--- open-vm-tools/Makefile	(revision 333567)
+++ open-vm-tools/Makefile	(working copy)
@@ -18,6 +18,29 @@
 RELEASE_VER=		8.6.0
 BUILD_VER=		425873
 
+OPTIONS_DEFINE=	X11 LIBNOTIFY UNITY FUSE DNET ICU
+OPTIONS_DEFAULT=	X11 LIBNOTIFY FUSE DNET ICU
+OPTIONS_SUB=
+
+DNET_DESC=	libdnet support
+LIBNOTIFY_DESC=	Desktop notification support
+UNITY_DESC=	liburiparser support
+
+X11_CONFIGURE_WITH=	x gtk2 gtkmm
+X11_LDFLAGS=		-L${LOCALBASE}/lib
+X11_USE=		xorg=x11 xorg=ice xorg=sm xorg=xext xorg=xineramaproto \
+			xorg=xinerama xorg=xrandr xorg=xrender xorg=xtst \
+			gnome=gtk20 gnome=gtkmm24
+X11_USES=		fuse
+LIBNOTIFY_LIB_DEPENDS=	libnotify.so:${PORTSDIR}/devel/libnotify
+UNITY_CONFIGURE_ENV=	CUSTOM_URIPARSER_CPPFLAGS="-I${LOCALBASE}/include/uriparser"
+UNITY_LIB_DEPENDS=	liburiparser.so:${PORTSDIR}/net/uriparser
+UNITY_CONFIGURE_ENABLE=	unity
+DNET_CONFIGURE_WITH=	dnet
+DNET_LIB_DEPENDS=		libdnet.so:${PORTSDIR}/net/libdnet
+ICU_CONFIGURE_WITH=	icu
+ICU_LIB_DEPENDS=		libicuuc.so:${PORTSDIR}/devel/icu
+
 WRKSRC=			${WRKDIR}/open-vm-tools-${RELEASE_VER}-${BUILD_VER}
 GNU_CONFIGURE=		yes
 USES=			pkgconfig kmod
@@ -29,53 +52,20 @@
 SSP_UNSAFE=		kernel module does not support ssp
 
 CONFIGURE_ARGS+=	--without-procps --sysconfdir=${LOCALBASE}/etc
-.if defined(WITHOUT_X11)
-CONFIGURE_ARGS+=	--without-x --without-gtk2 --without-gtkmm
-PLIST_SUB+=		X11="@comment "
-CONFLICTS=		open-vm-tools-[0-9]*
-.else
-.if !defined(WITHOUT_LIBNOTIFY)
-LIB_DEPENDS+=		libnotify.so:${PORTSDIR}/devel/libnotify
-.endif
-.if defined(WITH_UNITY)
-CONFIGURE_ENV+=		CUSTOM_URIPARSER_CPPFLAGS="-I${LOCALBASE}/include/uriparser"
-LIB_DEPENDS+=		liburiparser.so:${PORTSDIR}/net/uriparser
-.else
-CONFIGURE_ARGS+=	--disable-unity
-.endif
-CONFIGURE_ARGS+=	--with-x
-LDFLAGS+=		-L${LOCALBASE}/lib
-USE_XORG=		x11 ice sm xext xineramaproto xinerama xrandr xrender \
-			xtst
-USE_GNOME+=		gtk20 gtkmm24
-PLIST_SUB+=		X11=""
-CONFLICTS=		open-vm-tools-nox11-[0-9]*
-.endif
 
-.if !defined(WITHOUT_FUSE)
-USES+=		fuse
-PLIST_SUB+=	FUSE=""
-.else
-PLIST_SUB+=	FUSE="@comment "
-.endif
-
 CONFLICTS+=		vmware-guestd[0-9]* vmware-tools[0-9]*
 SUB_FILES=		pkg-message
 
-.if defined(WITHOUT_DNET)
-CONFIGURE_ARGS+=	--without-dnet
-.else
-LIB_DEPENDS+=		libdnet.so:${PORTSDIR}/net/libdnet
-.endif
+USE_RC_SUBR=		vmware-guestd vmware-kmod
 
-.if defined(WITHOUT_ICU)
-CONFIGURE_ARGS+=	--without-icu
+.include <bsd.port.options.mk>
+
+.if ${PORT_OPTIONS:MX11}
+CONFLICTS=		open-vm-tools-nox11-[0-9]*
 .else
-LIB_DEPENDS+=		libicuuc.so:${PORTSDIR}/devel/icu
+CONFLICTS=		open-vm-tools-[0-9]*
 .endif
 
-USE_RC_SUBR=		vmware-guestd vmware-kmod
-
 .include <bsd.port.pre.mk>
 
 .if ${ARCH} == "sparc64"
@@ -83,7 +73,7 @@
 .endif
 
 post-build:
-	(cd ${WRKSRC}/modules && env ${MAKE_ENV} ${MAKE} ${MAKE_ARGS})
+	cd ${WRKSRC}/modules && ${SETENV} ${MAKE_ENV} ${MAKE} ${MAKE_ARGS}
 
 post-install:
 	${MKDIR} ${STAGEDIR}${PREFIX}/lib/vmware-tools/modules/drivers
Index: open-vm-tools/pkg-plist
===================================================================
--- open-vm-tools/pkg-plist	(revision 333567)
+++ open-vm-tools/pkg-plist	(working copy)
@@ -47,9 +47,9 @@
 share/vmware-tools/resume-vm-default
 share/vmware-tools/suspend-vm-default
 share/vmware-tools/vm-support
-share/open-vm-tools/messages/de/toolbox.vmsg
-share/open-vm-tools/messages/ja/toolbox.vmsg
-share/open-vm-tools/messages/zh_CN/toolbox.vmsg
+%%DATADIR%%/messages/de/toolbox.vmsg
+%%DATADIR%%/messages/ja/toolbox.vmsg
+%%DATADIR%%/messages/zh_CN/toolbox.vmsg
 share/vmware-tools/statechange.subr
 share/vmware-tools/scripts/vmware/network
 @unexec if test -f %D/share/vmware-tools/tools.conf; then rm -f %D/share/vmware-tools/tools.conf; fi
@@ -58,14 +58,14 @@
 @dirrmtry lib/vmware-tools/modules
 @dirrmtry lib/vmware-tools
 @dirrmtry etc/vmware-tools
-@dirrmtry share/open-vm-tools/messages/de
-@dirrmtry share/open-vm-tools/messages/ja
-@dirrmtry share/open-vm-tools/messages/zh_CN
-@dirrmtry share/open-vm-tools/messages
-@dirrmtry share/open-vm-tools/scripts/vmware
-@dirrmtry share/open-vm-tools/scripts
-@dirrmtry share/open-vm-tools/tests
-@dirrmtry share/open-vm-tools
+@dirrmtry %%DATADIR%%/messages/de
+@dirrmtry %%DATADIR%%/messages/ja
+@dirrmtry %%DATADIR%%/messages/zh_CN
+@dirrmtry %%DATADIR%%/messages
+@dirrmtry %%DATADIR%%/scripts/vmware
+@dirrmtry %%DATADIR%%/scripts
+@dirrmtry %%DATADIR%%/tests
+@dirrmtry %%DATADIR%%
 @dirrmtry share/vmware-tools/scripts/vmware
 @dirrmtry share/vmware-tools/scripts
 @dirrmtry share/vmware-tools
Index: open-vm-tools-nox11/Makefile
===================================================================
--- open-vm-tools-nox11/Makefile	(revision 333567)
+++ open-vm-tools-nox11/Makefile	(working copy)
@@ -2,8 +2,7 @@
 # $FreeBSD$
 
 MASTERDIR=      ${.CURDIR}/../open-vm-tools
-WITHOUT_X11=    yes
 PKGNAMESUFFIX=	-nox11
+OPTIONS_EXCLUDE=	X11
 
-NO_STAGE=	yes
 .include "${MASTERDIR}/Makefile"
--- open-vm-tools-425873_4,1.patch ends here ---

>Release-Note:
>Audit-Trail:
>Unformatted:



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