Bug 183893 - [PATCH] emulators/open-vm-tools: Convert to new options framework
[PATCH] emulators/open-vm-tools: Convert to new options framework
Status: Closed FIXED
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s)
Latest
Any Any
: Normal Affects Only Me
Assigned To: Steve Wills
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2013-11-12 13:20 UTC by Mathieu Arnold
Modified: 2013-11-16 23:30 UTC (History)
1 user (show)

See Also:


Attachments
open-vm-tools-425873_4,1.patch (4.82 KB, patch)
2013-11-12 13:20 UTC, Mathieu Arnold
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Mathieu Arnold freebsd_committer 2013-11-12 13:20:00 UTC
- 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)
Comment 1 Edwin Groothuis freebsd_committer 2013-11-12 13:20:10 UTC
Responsible Changed
From-To: freebsd-ports-bugs->swills

Over to maintainer (via the GNATS Auto Assign Tool)
Comment 2 Steve Wills freebsd_committer 2013-11-16 14:19:05 UTC
State Changed
From-To: open->closed

Committed. Thanks!
Comment 3 dfilter freebsd_committer 2013-11-16 14:19:05 UTC
Author: swills
Date: Sat Nov 16 14:18:54 2013
New Revision: 333999
URL: http://svnweb.freebsd.org/changeset/ports/333999

Log:
  - Convert to new options framework
  - Pet portlint
  
  PR:		ports/183893
  Submitted by:	mat

Modified:
  head/emulators/open-vm-tools/Makefile
  head/emulators/open-vm-tools/pkg-plist

Modified: head/emulators/open-vm-tools/Makefile
==============================================================================
--- head/emulators/open-vm-tools/Makefile	Sat Nov 16 13:51:34 2013	(r333998)
+++ head/emulators/open-vm-tools/Makefile	Sat Nov 16 14:18:54 2013	(r333999)
@@ -18,6 +18,28 @@ LICENSE_FILE=		${WRKSRC}/COPYING
 RELEASE_VER=		9.2.3
 BUILD_VER=		1031360
 
+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,ice,sm,xext,xineramaproto,xinerama,xrandr,xrender,xtst \
+			gnome=gtk20,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,47 +51,20 @@ KMODDIR=		${PREFIX}/lib/vmware-tools/mod
 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
-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
+
+.include <bsd.port.options.mk>
 
-.if defined(WITHOUT_ICU)
-CONFIGURE_ARGS+=	--without-icu
+.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"
@@ -77,7 +72,7 @@ IGNORE=		not yet ported to sparc64
 .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

Modified: head/emulators/open-vm-tools/pkg-plist
==============================================================================
--- head/emulators/open-vm-tools/pkg-plist	Sat Nov 16 13:51:34 2013	(r333998)
+++ head/emulators/open-vm-tools/pkg-plist	Sat Nov 16 14:18:54 2013	(r333999)
@@ -52,14 +52,6 @@ share/vmware-tools/scripts/vmware/networ
 @dirrmtry lib/vmware-tools/modules/input
 @dirrmtry lib/vmware-tools/modules
 @dirrmtry lib/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 share/vmware-tools/scripts/vmware
 @dirrmtry share/vmware-tools/scripts
 @dirrmtry share/vmware-tools
_______________________________________________
svn-ports-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-ports-all
To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
Comment 4 dfilter freebsd_committer 2013-11-16 23:22:31 UTC
Author: swills
Date: Sat Nov 16 23:22:22 2013
New Revision: 334036
URL: http://svnweb.freebsd.org/changeset/ports/334036

Log:
  - Update to 9.4.0
  - Commit open-vm-tools-nox11 part of conversion to optionsNG missed in last
    commit [1]
  - Fix plist issue with open-vm-tools-nox11 with optionsNG enabled
  
  PR:		ports/183893 [1]
  Submitted by:	mat

Added:
  head/emulators/open-vm-tools/files/patch-vm_basic_asm.h   (contents, props changed)
Deleted:
  head/emulators/open-vm-tools/files/patch-hostinfoPosix.c
Modified:
  head/emulators/open-vm-tools-nox11/Makefile   (contents, props changed)
  head/emulators/open-vm-tools/Makefile
  head/emulators/open-vm-tools/distinfo
  head/emulators/open-vm-tools/files/patch-vmmemctl-os.c
  head/emulators/open-vm-tools/pkg-plist

Modified: head/emulators/open-vm-tools-nox11/Makefile
==============================================================================
--- head/emulators/open-vm-tools-nox11/Makefile	Sat Nov 16 22:35:22 2013	(r334035)
+++ head/emulators/open-vm-tools-nox11/Makefile	Sat Nov 16 23:22:22 2013	(r334036)
@@ -2,8 +2,7 @@
 # $FreeBSD$
 
 MASTERDIR=      ${.CURDIR}/../open-vm-tools
-WITHOUT_X11=    yes
 PKGNAMESUFFIX=	-nox11
+OPTIONS_UNSET=	X11
 
-NO_STAGE=	yes
 .include "${MASTERDIR}/Makefile"

Modified: head/emulators/open-vm-tools/Makefile
==============================================================================
--- head/emulators/open-vm-tools/Makefile	Sat Nov 16 22:35:22 2013	(r334035)
+++ head/emulators/open-vm-tools/Makefile	Sat Nov 16 23:22:22 2013	(r334036)
@@ -3,10 +3,10 @@
 
 PORTNAME=		open-vm-tools
 PORTVERSION=		${BUILD_VER}
-PORTREVISION=		4
+PORTREVISION=		0
 PORTEPOCH=		1
 CATEGORIES=		emulators
-MASTER_SITES=		SF/${PORTNAME}/${PORTNAME}/stable-9.2.x
+MASTER_SITES=		SF/${PORTNAME}/${PORTNAME}/stable-9.4.x
 DISTNAME=		open-vm-tools-${RELEASE_VER}-${BUILD_VER}
 
 MAINTAINER=		swills@FreeBSD.org
@@ -15,16 +15,16 @@ COMMENT?=		Open VMware tools for FreeBSD
 LICENSE=		LGPL21
 LICENSE_FILE=		${WRKSRC}/COPYING
 
-RELEASE_VER=		9.2.3
-BUILD_VER=		1031360
+RELEASE_VER=		9.4.0
+BUILD_VER=		1280544
 
-OPTIONS_DEFINE=	X11 LIBNOTIFY UNITY FUSE DNET ICU
+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
+DNET_DESC=		libdnet support
+LIBNOTIFY_DESC=		Desktop notification support
+UNITY_DESC=		liburiparser support
 
 X11_CONFIGURE_WITH=	x gtk2 gtkmm
 X11_LDFLAGS=		-L${LOCALBASE}/lib
@@ -36,9 +36,9 @@ UNITY_CONFIGURE_ENV=	CUSTOM_URIPARSER_CP
 UNITY_LIB_DEPENDS=	liburiparser.so:${PORTSDIR}/net/uriparser
 UNITY_CONFIGURE_ENABLE=	unity
 DNET_CONFIGURE_WITH=	dnet
-DNET_LIB_DEPENDS=		libdnet.so:${PORTSDIR}/net/libdnet
+DNET_LIB_DEPENDS=	libdnet.so:${PORTSDIR}/net/libdnet
 ICU_CONFIGURE_WITH=	icu
-ICU_LIB_DEPENDS=		libicuuc.so:${PORTSDIR}/devel/icu
+ICU_LIB_DEPENDS=	libicuuc.so:${PORTSDIR}/devel/icu
 
 WRKSRC=			${WRKDIR}/open-vm-tools-${RELEASE_VER}-${BUILD_VER}
 GNU_CONFIGURE=		yes

Modified: head/emulators/open-vm-tools/distinfo
==============================================================================
--- head/emulators/open-vm-tools/distinfo	Sat Nov 16 22:35:22 2013	(r334035)
+++ head/emulators/open-vm-tools/distinfo	Sat Nov 16 23:22:22 2013	(r334036)
@@ -1,2 +1,2 @@
-SHA256 (open-vm-tools-9.2.3-1031360.tar.gz) = 1a004ea1675101fd44cddda299e2e9ac254388769b69f41b7ff5d1797549c8f1
-SIZE (open-vm-tools-9.2.3-1031360.tar.gz) = 3565935
+SHA256 (open-vm-tools-9.4.0-1280544.tar.gz) = 5d30652eb0f6dc5e930781029c184837e700be5543b6a7116db4c62a6f3ca399
+SIZE (open-vm-tools-9.4.0-1280544.tar.gz) = 3659504

Added: head/emulators/open-vm-tools/files/patch-vm_basic_asm.h
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/emulators/open-vm-tools/files/patch-vm_basic_asm.h	Sat Nov 16 23:22:22 2013	(r334036)
@@ -0,0 +1,11 @@
+--- lib/include/vm_basic_asm.h.orig	2013-11-13 03:22:29.000000000 +0000
++++ lib/include/vm_basic_asm.h	2013-11-13 03:24:26.000000000 +0000
+@@ -208,7 +208,7 @@
+ GetCallerEFlags(void)
+ {
+    unsigned long flags;
+-   asm volatile("pushf; pop %0" : "=r"(flags));
++   __asm__ volatile("pushf; pop %0" : "=r"(flags));
+    return flags;
+ }
+ 

Modified: head/emulators/open-vm-tools/files/patch-vmmemctl-os.c
==============================================================================
--- head/emulators/open-vm-tools/files/patch-vmmemctl-os.c	Sat Nov 16 22:35:22 2013	(r334035)
+++ head/emulators/open-vm-tools/files/patch-vmmemctl-os.c	Sat Nov 16 23:22:22 2013	(r334036)
@@ -1,5 +1,5 @@
---- modules/freebsd/vmmemctl/os.c.orig	2011-09-21 20:25:15.000000000 +0200
-+++ modules/freebsd/vmmemctl/os.c	2013-10-19 11:01:27.000000000 +0200
+--- modules/freebsd/vmmemctl/os.c.orig	2013-09-23 15:51:10.000000000 +0000
++++ modules/freebsd/vmmemctl/os.c	2013-11-16 19:55:06.152925027 +0000
 @@ -37,9 +37,11 @@
  #include <sys/param.h>
  #include <sys/systm.h>
@@ -12,7 +12,33 @@
  #include <sys/sysctl.h>
  
  #include <vm/vm.h>
-@@ -264,14 +266,23 @@
+@@ -295,7 +297,13 @@
+ Mapping
+ OS_MapPageHandle(PageHandle handle)     // IN
+ {
++
++#if __FreeBSD_version >= 1000042
++   vm_offset_t res = kva_alloc(PAGE_SIZE);
++#else
+    vm_offset_t res = kmem_alloc_nofault(kernel_map, PAGE_SIZE);
++#endif
++
+    vm_page_t page = (vm_page_t)handle;
+ 
+    if (!res) {
+@@ -352,7 +360,11 @@
+ OS_UnmapPage(Mapping mapping)           // IN
+ {
+    pmap_qremove((vm_offset_t)mapping, 1);
++#if __FreeBSD_version >= 1000042
++   kva_free((vm_offset_t)mapping, PAGE_SIZE);
++#else
+    kmem_free(kernel_map, (vm_offset_t)mapping, PAGE_SIZE);
++#endif
+ }
+ 
+ 
+@@ -369,14 +381,23 @@
     p->size = (p->size + sizeof(unsigned long) - 1) & 
                           ~(sizeof(unsigned long) - 1);
  
@@ -29,14 +55,14 @@
  os_pmap_free(os_pmap *p) // IN
  {
 +#if __FreeBSD_version >= 1000042
-+   kmem_free(kernel_arena, (vm_offset_t)p->bitmap, p->size);
++   kva_free((vm_offset_t)p->bitmap, p->size);
 +#else
     kmem_free(kernel_map, (vm_offset_t)p->bitmap, p->size);
 +#endif
     p->size = 0;
     p->bitmap = NULL;
  }
-@@ -344,12 +355,31 @@
+@@ -449,12 +470,31 @@
     os_state *state = &global_state;
     os_pmap *pmap = &state->pmap;
  
@@ -73,7 +99,7 @@
  }
  
  
-@@ -361,8 +391,19 @@
+@@ -466,8 +506,19 @@
     os_state *state = &global_state;
     os_pmap *pmap = &state->pmap;
  
@@ -93,7 +119,7 @@
        return NULL;
     }
  
-@@ -383,6 +424,11 @@
+@@ -488,6 +539,11 @@
     if (!page) {
        os_pmap_putindex(pmap, pindex);
     }

Modified: head/emulators/open-vm-tools/pkg-plist
==============================================================================
--- head/emulators/open-vm-tools/pkg-plist	Sat Nov 16 22:35:22 2013	(r334035)
+++ head/emulators/open-vm-tools/pkg-plist	Sat Nov 16 23:22:22 2013	(r334036)
@@ -4,7 +4,7 @@ bin/vmware-rpctool
 bin/vmware-xferlogs
 bin/vmtoolsd
 bin/vmware-toolbox-cmd
-%%FUSE%%bin/vmware-vmblock-fuse
+%%X11%%%%FUSE%%bin/vmware-vmblock-fuse
 lib/open-vm-tools/plugins/vmsvc/libguestInfo.so
 lib/open-vm-tools/plugins/vmsvc/libpowerOps.so
 lib/open-vm-tools/plugins/vmsvc/libtimeSync.so
_______________________________________________
svn-ports-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-ports-all
To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"