From owner-freebsd-ports-bugs@FreeBSD.ORG Mon Dec 28 21:50:06 2009 Return-Path: Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3BE221065670 for ; Mon, 28 Dec 2009 21:50:06 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id F3C868FC19 for ; Mon, 28 Dec 2009 21:50:05 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.3/8.14.3) with ESMTP id nBSLo5Oh074385 for ; Mon, 28 Dec 2009 21:50:05 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.3/8.14.3/Submit) id nBSLo5VP074384; Mon, 28 Dec 2009 21:50:05 GMT (envelope-from gnats) Resent-Date: Mon, 28 Dec 2009 21:50:05 GMT Resent-Message-Id: <200912282150.nBSLo5VP074384@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Steve Wills Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 07210106566C for ; Mon, 28 Dec 2009 21:45:44 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21]) by mx1.freebsd.org (Postfix) with ESMTP id EA3398FC12 for ; Mon, 28 Dec 2009 21:45:43 +0000 (UTC) Received: from www.freebsd.org (localhost [127.0.0.1]) by www.freebsd.org (8.14.3/8.14.3) with ESMTP id nBSLjh1V028793 for ; Mon, 28 Dec 2009 21:45:43 GMT (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.14.3/8.14.3/Submit) id nBSLjhRA028792; Mon, 28 Dec 2009 21:45:43 GMT (envelope-from nobody) Message-Id: <200912282145.nBSLjhRA028792@www.freebsd.org> Date: Mon, 28 Dec 2009 21:45:43 GMT From: Steve Wills To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: ports/142112: update emulators/open-vm-tools to newer version X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 28 Dec 2009 21:50:06 -0000 >Number: 142112 >Category: ports >Synopsis: update emulators/open-vm-tools to newer version >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: Mon Dec 28 21:50:05 UTC 2009 >Closed-Date: >Last-Modified: >Originator: Steve Wills >Release: FreeBSD 8.0 >Organization: >Environment: >Description: This updates the emulators/open-vm-tools port to a newer version, see attached. >How-To-Repeat: >Fix: Patch attached with submission follows: # This is a shell archive. Save it in a file, remove anything before # this line, and then unpack it by entering "sh file". Note, it may # create directories; files and directories will be owned by you and # have default permissions. # # This archive contains: # # open-vm-tools/files/vmware-kmod.sh.in # open-vm-tools/files/patch-freebsd-8 # open-vm-tools/files/patch-scripts-Makefile # open-vm-tools/files/patch-services-Makefile # open-vm-tools/files/patch-hgfsmounter-Makefile.in # open-vm-tools/files/patch-modules-Makefile.in # open-vm-tools/files/patch-vmtoolsd-Makefile.in # open-vm-tools/files/patch-guestApp.c # open-vm-tools/files/patch-util_misc.c # open-vm-tools/files/patch-vmhgfs-state.c # open-vm-tools/files/patch-vmmemctl-os.c # open-vm-tools/files/patch-getpwnam # open-vm-tools/files/pkg-message.in # open-vm-tools/files/vmware-guestd.sh.in # open-vm-tools/files/patch-arch # open-vm-tools/Makefile # open-vm-tools/distinfo # open-vm-tools/pkg-descr # open-vm-tools/pkg-plist # echo x - open-vm-tools/files/vmware-kmod.sh.in sed 's/^X//' >open-vm-tools/files/vmware-kmod.sh.in << '0ac332b2072975a17d019ec5c6c5f8cf' X#!/bin/sh X# X# $FreeBSD: ports/emulators/open-vm-tools/files/vmware-kmod.sh.in,v 1.6 2009/03/25 18:18:11 mbr Exp $ X# X X# PROVIDE: vmware-kmod X# REQUIRE: FILESYSTEMS X# BEFORE: netif X X. %%RC_SUBR%% X X# Global Xcheckvm_cmd="%%PREFIX%%/bin/vmware-checkvm > /dev/null" X X# Functions Xvmware_guest_vmmemctl_start() X{ X echo 'Loading vmmemctl kernel module.' X kldload %%PREFIX%%/lib/vmware-tools/modules/drivers/vmmemctl.ko >/dev/null 2>&1 X} Xvmware_guest_vmxnet_start() X{ X echo 'Loading vmxnet kernel module.' X kldload %%PREFIX%%/lib/vmware-tools/modules/drivers/vmxnet.ko >/dev/null 2>&1 X} Xvmware_guest_vmblock_start() X{ X echo 'Loading vmblock kernel module.' X kldload %%PREFIX%%/lib/vmware-tools/modules/drivers/vmblock.ko >/dev/null 2>&1 X} Xvmware_guest_vmhgfs_start() X{ X echo 'Loading vmhgfs kernel module.' X kldload %%PREFIX%%/lib/vmware-tools/modules/drivers/vmhgfs.ko >/dev/null 2>&1 X} X X# VMware kernel module: vmmemctl Xname="vmware_guest_vmmemctl" Xrcvar=`set_rcvar` Xstart_precmd="${checkvm_cmd}" Xstart_cmd="vmware_guest_vmmemctl_start" Xstop_precmd="${checkvm_cmd}" Xstop_cmd=":" X Xload_rc_config $name X[ -z "$vmware_guest_vmmemctl_enable" ] && vmware_guest_vmmemctl_enable="NO" X[ -n "$vmware_guest_kmod_enable" ] && vmware_guest_vmmemctl_enable="$vmware_guest_kmod_enable" Xrun_rc_command "$1" X X# VMware kernel module: vmxnet Xname="vmware_guest_vmxnet" Xrcvar=`set_rcvar` Xstart_precmd="${checkvm_cmd}" Xstart_cmd="vmware_guest_vmxnet_start" Xstop_precmd="${checkvm_cmd}" Xstop_cmd=":" X Xload_rc_config $name X[ -z "$vmware_guest_vmxnet_enable" ] && vmware_guest_vmxnet_enable="NO" Xrun_rc_command "$1" X X# VMware kernel module: vmblock Xname="vmware_guest_vmblock" Xrcvar=`set_rcvar` Xstart_precmd="${checkvm_cmd}" Xstart_cmd="vmware_guest_vmblock_start" Xstop_precmd="${checkvm_cmd}" Xstop_cmd=":" X Xload_rc_config $name X[ -z "$vmware_guest_vmblock_enable" ] && vmware_guest_vmblock_enable="NO" Xrun_rc_command "$1" X X# VMware kernel module: vmhgfs Xname="vmware_guest_vmhgfs" Xrcvar=`set_rcvar` Xstart_precmd="${checkvm_cmd}" Xstart_cmd="vmware_guest_vmhgfs_start" Xstop_precmd="${checkvm_cmd}" Xstop_cmd=":" X Xload_rc_config $name X[ -z "$vmware_guest_vmhgfs_enable" ] && vmware_guest_vmhgfs_enable="NO" Xrun_rc_command "$1" 0ac332b2072975a17d019ec5c6c5f8cf echo x - open-vm-tools/files/patch-freebsd-8 sed 's/^X//' >open-vm-tools/files/patch-freebsd-8 << '6b0ed6034909bf98a214a08de3f44b92' X--- modules/freebsd/vmhgfs/vnops.c.orig 2009-02-18 17:02:35.000000000 +0900 X+++ modules/freebsd/vmhgfs/vnops.c 2009-03-01 17:47:10.000000000 +0900 X@@ -325,7 +325,11 @@ X */ X { X struct vnode *vp = ap->a_vp; X+#if __FreeBSD_version >= 800001 X+ int mode = ap->a_accmode; X+#else X int mode = ap->a_mode; X+#endif X HgfsAccessMode accessMode = 0; X Bool isDir = vp->v_type == VDIR; X if (mode & VREAD) { X--- modules/freebsd/vmblock/vfsops.c.orig 2009-03-18 03:03:21.000000000 -0400 X+++ modules/freebsd/vmblock/vfsops.c 2009-05-23 02:25:50.892549675 -0400 X@@ -126,6 +126,11 @@ X char *target; X int len, error = 0; X X+#if __FreeBSD_version >= 800087 X+ struct thread *td; X+ td = curthread; X+#endif X+ X VMBLOCKDEBUG("VMBlockVFSMount(mp = %p)\n", (void *)mp); X X /* X@@ -273,6 +278,11 @@ X int error; X int flags = 0, removed = 0; X X+#if __FreeBSD_version >= 800087 X+ struct thread *td; X+ td = curthread; X+#endif X+ X VMBLOCKDEBUG("VMBlockVFSUnmount: mp = %p\n", (void *)mp); X X xmp = MNTTOVMBLOCKMNT(mp); X@@ -448,10 +458,15 @@ X VMBlockVFSSync(struct mount *mp, // Ignored X int waitfor) // Ignored X #else X+#if __FreeBSD_version >= 800087 X+VMBlockVFSSync(struct mount *mp, X+ int waitfor) X+#else X VMBlockVFSSync(struct mount *mp, // Ignored X int waitfor, // Ignored X struct thread *td) // Ignored X #endif X+#endif X { X return 0; X } X--- modules/freebsd/vmhgfs/vfsops.c.orig 2009-03-18 03:03:26.000000000 -0400 X+++ modules/freebsd/vmhgfs/vfsops.c 2009-05-23 02:56:39.608109670 -0400 X@@ -109,8 +109,12 @@ X */ X X static int X+#if __FreeBSD_version >= 800087 X+HgfsVfsMount(struct mount *mp) X+#else X HgfsVfsMount(struct mount *mp, // IN: structure representing the file system X struct thread *td) // IN: thread which is mounting the file system X+#endif X { X HgfsSuperInfo *sip; X struct vnode *vp; X@@ -122,6 +126,10 @@ X int *uid = NULL; X Bool *gidSet = NULL; X int *gid = NULL; X+#if __FreeBSD_version >= 800087 X+ struct thread *td; X+ td = curthread; X+#endif X X /* X * - Examine/validate mount flags from userland. X@@ -145,7 +153,11 @@ X * Since Hgfs requires the caller to be root, only allow mount attempts made X * by the superuser. X */ X+#if __FreeBSD_version >= 800001 X+ if ((ret = priv_check(td, PRIV_VFS_MOUNT)) != 0) { X+#else X if ((ret = suser(td)) != 0) { X+#endif X return ret; X } X X@@ -277,11 +289,19 @@ X */ X X static int X+#if __FreeBSD_version >= 800087 X+HgfsVfsUnmount(struct mount *mp, int mntflags) X+#else X HgfsVfsUnmount(struct mount *mp, int mntflags, struct thread *td) X+#endif X { X HgfsSuperInfo *sip; X int ret = 0; X int flags = 0; X+#if __FreeBSD_version >= 800087 X+ struct thread *td; X+ td = curthread; X+#endif X X sip = (HgfsSuperInfo *)mp->mnt_data; X X@@ -348,10 +368,18 @@ X */ X X static int X+#if __FreeBSD_version >= 800087 X+HgfsVfsStatfs(struct mount *mp, struct statfs *sbp) X+#else X HgfsVfsStatfs(struct mount *mp, struct statfs *sbp, struct thread *td) X+#endif X { X int ret = 0; X struct vnode *vp; X+#if __FreeBSD_version >= 800087 X+ struct thread *td; X+ td = curthread; X+#endif X X /* We always want HGFS_BLOCKSIZE to be a power of two */ X ASSERT_ON_COMPILE(HGFS_IS_POWER_OF_TWO(HGFS_BLOCKSIZE)); X@@ -361,8 +389,11 @@ X * we got from a call to vfs_getnewfsid() in HgfsVfsMount() X */ X bcopy(&mp->mnt_stat, sbp, sizeof mp->mnt_stat); X- X+#if __FreeBSD_version >= 800087 X+ ret = HgfsVfsRoot(mp, LK_SHARED, &vp); X+#else X ret = HgfsVfsRoot(mp, LK_SHARED, &vp, td); X+#endif X if (ret) { X DEBUG(VM_DEBUG_FAIL, "HgfsVfsRoot failed\n"); X return ret; X@@ -397,13 +428,23 @@ X */ X X static int X+#if __FreeBSD_version >= 800087 X+HgfsVfsRoot(struct mount *mp, X+ int flags, X+ struct vnode **vpp) X+#else X HgfsVfsRoot(struct mount *mp, // IN: Filesystem structure X int flags, // IN: Flags to vget X struct vnode **vpp, // OUT: Address of root vnode X struct thread *td) // IN: Thread structure X+#endif X { X HgfsSuperInfo *sip = (HgfsSuperInfo *)mp->mnt_data; X int ret = 0; X+#if __FreeBSD_version >= 800087 X+ struct thread *td; X+ td = curthread; X+#endif X X *vpp = NULL; X 6b0ed6034909bf98a214a08de3f44b92 echo x - open-vm-tools/files/patch-scripts-Makefile sed 's/^X//' >open-vm-tools/files/patch-scripts-Makefile << '9af76abd47b69a1f82b1db5908fa8ac5' X--- scripts/Makefile.am.orig 2008-07-22 01:13:49.000000000 +0200 X+++ scripts/Makefile.am 2008-07-22 01:17:50.000000000 +0200 X@@ -1,4 +1,4 @@ X-confdir = /etc/vmware-tools X+confdir = ${prefix}/share/vmware-tools X X conf_SCRIPTS = ./common/vm-support X conf_SCRIPTS += $(MODULES_OS)/poweron-vm-default X--- scripts/Makefile.in.orig 2008-07-22 01:13:57.000000000 +0200 X+++ scripts/Makefile.in 2008-07-22 01:18:30.000000000 +0200 X@@ -236,7 +236,7 @@ X target_alias = @target_alias@ X top_builddir = @top_builddir@ X top_srcdir = @top_srcdir@ X-confdir = /etc/vmware-tools X+confdir = ${prefix}/share/vmware-tools X conf_SCRIPTS = ./common/vm-support $(MODULES_OS)/poweron-vm-default \ X $(MODULES_OS)/poweroff-vm-default \ X $(MODULES_OS)/suspend-vm-default \ 9af76abd47b69a1f82b1db5908fa8ac5 echo x - open-vm-tools/files/patch-services-Makefile sed 's/^X//' >open-vm-tools/files/patch-services-Makefile << 'f2cb87b327a8d708f39350e85156dd54' X--- services/Makefile.am.orig 2009-02-28 20:48:46.000000000 +0100 X+++ services/Makefile.am 2009-02-28 20:49:28.000000000 +0100 X@@ -20,6 +20,6 @@ X SUBDIRS += plugins X X install-exec-local: X- mkdir -p $(DESTDIR)/etc/vmware-tools X- ln -sf `dirname $(VMSVC_PLUGIN_INSTALLDIR)` $(DESTDIR)/etc/vmware-tools/plugins X+ mkdir -p $(prefix)/etc/vmware-tools X+ X X--- services/Makefile.in.orig 2009-02-28 20:48:52.000000000 +0100 X+++ services/Makefile.in 2009-02-28 20:49:46.000000000 +0100 X@@ -576,8 +576,8 @@ X X X install-exec-local: X- mkdir -p $(DESTDIR)/etc/vmware-tools X- ln -sf `dirname $(VMSVC_PLUGIN_INSTALLDIR)` $(DESTDIR)/etc/vmware-tools/plugins X+ mkdir -p $(prefix)/etc/vmware-tools X+ X # Tell versions [3.59,3.63) of GNU make to not export all variables. X # Otherwise a system limit (for SysV at least) may be exceeded. X .NOEXPORT: f2cb87b327a8d708f39350e85156dd54 echo x - open-vm-tools/files/patch-hgfsmounter-Makefile.in sed 's/^X//' >open-vm-tools/files/patch-hgfsmounter-Makefile.in << 'd1a5c14c889eae1b84f565be09ad2b93' X--- hgfsmounter/Makefile.in.orig 2009-04-06 17:24:30.000000000 -0400 X+++ hgfsmounter/Makefile.in 2009-04-06 17:26:09.000000000 -0400 X@@ -569,9 +569,9 @@ X @FREEBSD_TRUE@ mv $(DESTDIR)$(sbindir)/mount.vmhgfs \ X @FREEBSD_TRUE@ $(DESTDIR)$(sbindir)/mount_vmhgfs X @FREEBSD_TRUE@@WITH_ROOT_PRIVILEGES_TRUE@ chmod u+s $(DESTDIR)$(sbindir)/mount_vmhgfs X-@FREEBSD_TRUE@ -$(MKDIR_P) $(DESTDIR)/sbin X-@FREEBSD_TRUE@ -$(LN_S) $(DESTDIR)$(sbindir)/mount_vmhgfs \ X-@FREEBSD_TRUE@ $(DESTDIR)/sbin/mount_vmhgfs &> /dev/null X+#@FREEBSD_TRUE@ -$(MKDIR_P) $(DESTDIR)/sbin X+#@FREEBSD_TRUE@ -$(LN_S) $(DESTDIR)$(sbindir)/mount_vmhgfs \ X+#@FREEBSD_TRUE@ $(DESTDIR)/sbin/mount_vmhgfs &> /dev/null X @FREEBSD_TRUE@uninstall-hook: X @FREEBSD_TRUE@ rm -f $(DESTDIR)$(sbindir)/mount_vmhgfs X @FREEBSD_FALSE@install-exec-hook: d1a5c14c889eae1b84f565be09ad2b93 echo x - open-vm-tools/files/patch-modules-Makefile.in sed 's/^X//' >open-vm-tools/files/patch-modules-Makefile.in << 'f946a57f991208d11285ba0616e6e327' X--- modules/Makefile.in.orig 2009-04-06 18:44:58.000000000 -0400 X+++ modules/Makefile.in 2009-04-06 18:45:57.000000000 -0400 X@@ -528,11 +528,11 @@ X @SOLARIS_TRUE@ $(MAKE) VM_UNAME=$(KERNEL_RELEASE) MV=mv RM=rm \ X @SOLARIS_TRUE@ -C "$(modulesrc)/$(MODULES_OS)/$$MOD" install || exit 1; \ X @SOLARIS_TRUE@ done X-@FREEBSD_TRUE@ for MOD in $(MODULES); do \ X-@FREEBSD_TRUE@ $(INSTALL) -d $(DESTDIR)$(MODULES_DIR); \ X-@FREEBSD_TRUE@ $(INSTALL) -m644 $(modulesrc)/$(MODULES_OS)/$$MOD.ko \ X-@FREEBSD_TRUE@ $(DESTDIR)$(MODULES_DIR); \ X-@FREEBSD_TRUE@ done X+#@FREEBSD_TRUE@ for MOD in $(MODULES); do \ X+#@FREEBSD_TRUE@ $(INSTALL) -d $(DESTDIR)$(MODULES_DIR); \ X+#@FREEBSD_TRUE@ $(INSTALL) -m644 $(modulesrc)/$(MODULES_OS)/$$MOD.ko \ X+#@FREEBSD_TRUE@ $(DESTDIR)$(MODULES_DIR); \ X+#@FREEBSD_TRUE@ done X @LINUX_TRUE@ for MOD in $(MODULES); do \ X @LINUX_TRUE@ $(INSTALL) -d $(DESTDIR)`eval echo '$$'$${MOD}dir`; \ X @LINUX_TRUE@ $(INSTALL) -m644 $(modulesrc)/$(MODULES_OS)/$$MOD/$$MOD.ko \ f946a57f991208d11285ba0616e6e327 echo x - open-vm-tools/files/patch-vmtoolsd-Makefile.in sed 's/^X//' >open-vm-tools/files/patch-vmtoolsd-Makefile.in << '018601cc2d92e267d800128e06cc6b4f' X--- services/vmtoolsd/Makefile.in.orig 2009-04-06 18:40:27.000000000 -0400 X+++ services/vmtoolsd/Makefile.in 2009-04-06 18:41:16.000000000 -0400 X@@ -722,7 +722,7 @@ X $@ || (rm -f $@ && exit 1) X X install-exec-hook: X- $(INSTALL) -d $(DESTDIR)/etc/vmware-tools X+# $(INSTALL) -d $(DESTDIR)/etc/vmware-tools X X uninstall-hook: X rm -rf $(DESTDIR)/etc/vmware-tools 018601cc2d92e267d800128e06cc6b4f echo x - open-vm-tools/files/patch-guestApp.c sed 's/^X//' >open-vm-tools/files/patch-guestApp.c << '32d10b709465a944529796c96479e390' X--- lib/guestApp/guestApp.c.orig 2008-05-29 10:42:37.000000000 +0300 X+++ lib/guestApp/guestApp.c 2008-05-29 10:43:09.000000000 +0300 X@@ -73,7 +73,7 @@ X #elif defined(_WIN32) X #define GUESTAPP_TOOLS_INSTALL_PATH "" X #else X-#define GUESTAPP_TOOLS_INSTALL_PATH "/etc/vmware-tools" X+#define GUESTAPP_TOOLS_INSTALL_PATH "/usr/local/share/vmware-tools" X #endif X X /* 32d10b709465a944529796c96479e390 echo x - open-vm-tools/files/patch-util_misc.c sed 's/^X//' >open-vm-tools/files/patch-util_misc.c << 'd3d67e0effd234177f172ac975d28e9e' X--- lib/misc/util_misc.c.orig 2009-04-14 02:38:09.000000000 +0200 X+++ lib/misc/util_misc.c 2009-04-14 02:39:00.000000000 +0200 X@@ -292,7 +292,7 @@ X return (strcmp(path1, path2) == 0); X #elif defined(_WIN32) X return (_stricmp(path1, path2) == 0); X-#elif defined(__APPLE__) X+#elif defined(__APPLE__) || defined(__FreeBSD__) X return (strcasecmp(path1, path2) == 0); X #else X NOT_IMPLEMENTED(); X@@ -319,7 +319,7 @@ X Bool X Util_IsAbsolutePath(const char *path) // IN: path to check X { X-#if defined(__linux__) || defined(__APPLE__) X+#if defined(__linux__) || defined(__APPLE__) || defined(__FreeBSD__) X // path[0] is valid even for the empty string. X return path && path[0] == DIRSEPC; X #elif defined(_WIN32) d3d67e0effd234177f172ac975d28e9e echo x - open-vm-tools/files/patch-vmhgfs-state.c sed 's/^X//' >open-vm-tools/files/patch-vmhgfs-state.c << 'adf9c8c5e8e4d1d10e20da411856ede1' X--- modules/freebsd/vmhgfs/state.c.orig 2009-02-28 23:06:10.000000000 +0100 X+++ modules/freebsd/vmhgfs/state.c 2009-02-28 23:08:59.000000000 +0100 X@@ -770,6 +770,12 @@ X goto destroyVnode; X } X X+#if __FreeBSD_version >= 700034 X+ if ((ret = insmntque(vp, vfsp)) != 0) { X+ return ret; X+ } X+#endif X+ X /* X * Now we'll initialize the vnode. We need to set the file type, vnode X * operations, flags, filesystem pointer, reference count, and device. adf9c8c5e8e4d1d10e20da411856ede1 echo x - open-vm-tools/files/patch-vmmemctl-os.c sed 's/^X//' >open-vm-tools/files/patch-vmmemctl-os.c << '258d47c434863d0eda709990a066ce2b' X--- modules/freebsd/vmmemctl/os.c.orig 2009-04-09 15:18:08.000000000 -0400 X+++ modules/freebsd/vmmemctl/os.c 2009-04-09 15:34:06.000000000 -0400 X@@ -413,12 +413,14 @@ X os_state *state = &global_state; X os_pmap *pmap = &state->pmap; X X- if ( !vm_page_lookup(state->vmobject, page->pindex) ) { X- return; X+ VM_OBJECT_LOCK(state->vmobject); X+ if ( vm_page_lookup(state->vmobject, page->pindex) ) { X+ os_pmap_putindex(pmap, page->pindex); X+ vm_page_lock_queues(); X+ vm_page_free(page); X+ vm_page_unlock_queues(); X } X- X- os_pmap_putindex(pmap, page->pindex); X- vm_page_free(page); X+ VM_OBJECT_UNLOCK(state->vmobject); X } X X static vm_page_t os_kmem_alloc(int alloc_normal_failed) X@@ -430,8 +432,11 @@ X os_state *state = &global_state; X os_pmap *pmap = &state->pmap; X X+ VM_OBJECT_LOCK(state->vmobject); X+ X pindex = os_pmap_getindex(pmap); X if (pindex == (vm_pindex_t)-1) { X+ VM_OBJECT_UNLOCK(state->vmobject); X return NULL; X } X X@@ -452,6 +457,7 @@ X if (!page) { X os_pmap_putindex(pmap, pindex); X } X+ VM_OBJECT_UNLOCK(state->vmobject); X X return page; X } 258d47c434863d0eda709990a066ce2b echo x - open-vm-tools/files/patch-getpwnam sed 's/^X//' >open-vm-tools/files/patch-getpwnam << '77552b4f6b6c64dc85248d9ed81ae729' X--- lib/auth/authPosix.c 2008-03-19 08:49:49.000000000 +0100 X+++ lib/auth/authPosix.c 2008-03-27 11:20:20.000000000 +0100 X@@ -264,7 +264,11 @@ X #endif X /* If this point is reached, the user has been authenticated. */ X setpwent(); X+#if defined(__FreeBSD__) X+ pwd = getpwnam(user); X+#else X pwd = Posix_Getpwnam(user); X+#endif X endpwent(); X X #else /* !USE_PAM */ X@@ -274,7 +278,11 @@ X corresponding #endif below. */ X X setpwent(); //XXX can kill? X+#if defined(__FreeBSD__) X+ pwd = getpwnam(user); X+#else X pwd = Posix_Getpwnam(user); X+#endif X endpwent(); //XXX can kill? X X if (!pwd) { X--- lib/impersonate/impersonatePosix.c 2008-03-19 08:49:50.000000000 +0100 X+++ lib/impersonate/impersonatePosix.c 2008-03-27 11:21:38.000000000 +0100 X@@ -432,7 +432,11 @@ X struct passwd *ppw = &pw; X int error; X X+#if defined(__FreeBSD__) X+ if ((error = getpwnam_r(user, &pw, buffer, BUFSIZ, &ppw)) != 0 || !ppw) { X+#else X if ((error = Posix_Getpwnam_r(user, &pw, buffer, BUFSIZ, &ppw)) != 0 || !ppw) { X+#endif X if (error == 0) { X error = ENOENT; X } 77552b4f6b6c64dc85248d9ed81ae729 echo x - open-vm-tools/files/pkg-message.in sed 's/^X//' >open-vm-tools/files/pkg-message.in << '8152be0d4af0b293e85b2260ba23ab66' X******************************************************************* XTo run the Open Virtual Machine tools at startup, add the following Xsettings to your /etc/rc.conf X Xvmware_guest_vmblock_enable="YES" Xvmware_guest_vmhgfs_enable="YES" Xvmware_guest_vmmemctl_enable="YES" Xvmware_guest_vmxnet_enable="YES" Xvmware_guestd_enable="YES" X X******************************************************************* 8152be0d4af0b293e85b2260ba23ab66 echo x - open-vm-tools/files/vmware-guestd.sh.in sed 's/^X//' >open-vm-tools/files/vmware-guestd.sh.in << '1dde4bc4120d2cba80d5bdec30cc076b' X#!/bin/sh X# X# $FreeBSD: ports/emulators/open-vm-tools/files/vmware-guestd.sh.in,v 1.5 2009/06/08 23:24:44 mbr Exp $ X# X X# PROVIDE: vmware-guestd X# REQUIRE: DAEMON X# BEFORE: LOGIN X X. %%RC_SUBR%% X X# Global Xcheckvm_cmd="%%PREFIX%%/bin/vmware-checkvm > /dev/null" X X# VMware guest daemon Xname="vmware_guestd" Xrcvar=`set_rcvar` Xstart_precmd="${checkvm_cmd}" Xunset start_cmd Xstop_precmd="${checkvm_cmd}" Xunset stop_cmd Xcommand="%%PREFIX%%/bin/vmtoolsd" Xcommand_args="-c %%PREFIX%%/share/vmware-tools/tools.conf -p %%PREFIX%%/lib/open-vm-tools/plugins/vmsvc" Xpidfile="/var/run/${name}.pid" X Xload_rc_config $name X[ -z "$vmware_guestd_enable" ] && vmware_guestd_enable="YES" X[ -z "$vmware_guestd_flags" ] && vmware_guestd_flags="--background ${pidfile}" Xrun_rc_command "$1" 1dde4bc4120d2cba80d5bdec30cc076b echo x - open-vm-tools/files/patch-arch sed 's/^X//' >open-vm-tools/files/patch-arch << 'b786179a577fb694e94977aa1319a5be' X--- configure.orig 2008-03-28 10:36:13.000000000 +0100 X+++ configure 2008-03-28 10:36:45.000000000 +0100 X@@ -2259,6 +2259,9 @@ X x86_64) X userSpaceBitness="64" X ;; X+ amd64) X+ userSpaceBitness="64" X+ ;; X *) X { { echo "$as_me:$LINENO: error: Unknown architecture." >&5 X echo "$as_me: error: Unknown architecture." >&2;} b786179a577fb694e94977aa1319a5be echo x - open-vm-tools/Makefile sed 's/^X//' >open-vm-tools/Makefile << 'bb3eb2c2640490edebcb094dc52b7220' X# New ports collection makefile for: open-vm-tools for FreeBSD X# Date created: 28 Mar 2008 X# Whom: mbr@FreeBSD.org X# X# $FreeBSD: ports/emulators/open-vm-tools/Makefile,v 1.34 2009/08/22 00:20:23 amdmi3 Exp $ X# X XPORTNAME= open-vm-tools XPORTVERSION= ${BUILD_VER} XCATEGORIES= emulators kld XMASTER_SITES= SF/${PORTNAME}/${PORTNAME}/${RELEASE_DATE} XDISTNAME= open-vm-tools-${RELEASE_DATE}-${BUILD_VER} X XMAINTAINER= mbr@freebsd.org XCOMMENT?= Open VMware tools for FreeBSD VMware guests X XRELEASE_DATE= 2009.11.16 XBUILD_VER= 210370 X XWRKSRC= ${WRKDIR}/open-vm-tools-2009.11.17-210370 XGNU_CONFIGURE= yes XUSE_LDCONFIG= yes X XCONFIGURE_ARGS+= --without-procps --sysconfdir=${LOCALBASE}/etc X.if defined(WITHOUT_X11) XLIB_DEPENDS+= glib-2.0:${PORTSDIR}/devel/glib20 XCONFIGURE_ARGS+= --without-x --without-gtk2 --without-gtkmm XPLIST_SUB+= X11="@comment " XCONFLICTS= open-vm-tools-[0-9]* X.else X.if !defined(WITHOUT_LIBNOTIFY) XLIB_DEPENDS+= notify.1:${PORTSDIR}/devel/libnotify X.endif X.if defined(WITH_UNITY) XCONFIGURE_ENV+= CUSTOM_URIPARSER_CPPFLAGS="-I${LOCALBASE}/include/uriparser" XLIB_DEPENDS+= uriparser.1:${PORTSDIR}/net/uriparser X.else XCONFIGURE_ARGS+= --disable-unity X.endif XLIB_DEPENDS+= gtkmm-2.4:${PORTSDIR}/x11-toolkits/gtkmm24 XCONFIGURE_ARGS+= --with-x XCONFIGURE_ENV+= LDFLAGS="-L${LOCALBASE}/lib" \ X CPPFLAGS="-I${LOCALBASE}/include" XUSE_XORG= x11 ice sm xext xineramaproto xinerama xrandr xrender \ X xtst XUSE_GNOME= gtk20 glib20 XPLIST_SUB+= X11="" XCONFLICTS= open-vm-tools-nox11-[0-9]* X.endif X X.if !defined(WITHOUT_FUSE) XLIB_DEPENDS+= fuse.2:${PORTSDIR}/sysutils/fusefs-libs XRUN_DEPENDS+= mount_fusefs:${PORTSDIR}/sysutils/fusefs-kmod XPLIST_SUB+= FUSE="" X.else XPLIST_SUB+= FUSE="@comment " X.endif X XCONFLICTS+= vmware-guestd[0-9]* vmware-tools[0-9]* XSUB_FILES= pkg-message X X.if defined(WITHOUT_DNET) XCONFIGURE_ARGS+= --without-dnet X.else XLIB_DEPENDS+= dnet:${PORTSDIR}/net/libdnet X.endif X X.if defined(WITHOUT_ICU) XCONFIGURE_ARGS+= --without-icu X.else XLIB_DEPENDS+= icuuc:${PORTSDIR}/devel/icu X.endif X XUSE_RC_SUBR= vmware-guestd.sh vmware-kmod.sh X X.include X X.if ${OSVERSION} < 700000 XBROKEN= does not compile on 6.X X.endif X X.if ${ARCH} == "sparc64" XIGNORE= not yet ported to sparc64 X.endif X Xpost-build: X (cd ${WRKSRC}/modules && ${MAKE}) X Xpost-install: X ${MKDIR} ${PREFIX}/lib/vmware-tools/modules/drivers X ${MKDIR} ${PREFIX}/lib/vmware-tools/modules/input X ${INSTALL_DATA} ${WRKSRC}/modules/freebsd/vmmemctl.ko ${PREFIX}/lib/vmware-tools/modules/drivers/vmmemctl.ko X ${INSTALL_DATA} ${WRKSRC}/modules/freebsd/vmxnet.ko ${PREFIX}/lib/vmware-tools/modules/drivers/vmxnet.ko X ${INSTALL_DATA} ${WRKSRC}/modules/freebsd/vmhgfs.ko ${PREFIX}/lib/vmware-tools/modules/drivers/vmhgfs.ko X ${INSTALL_DATA} ${WRKSRC}/modules/freebsd/vmblock.ko ${PREFIX}/lib/vmware-tools/modules/drivers/vmblock.ko X @-kldxref ${PREFIX}/lib/vmware-tools/modules/drivers 2>/dev/null X @${CAT} ${PKGMESSAGE} X X.include bb3eb2c2640490edebcb094dc52b7220 echo x - open-vm-tools/distinfo sed 's/^X//' >open-vm-tools/distinfo << 'a39f43b1b241daee8e1a12ca67ace65a' XMD5 (open-vm-tools-2009.11.16-210370.tar.gz) = 93d28b6e57b8d1ad0d322dd881e11903 XSHA256 (open-vm-tools-2009.11.16-210370.tar.gz) = d0eb942bc913350526c734e71661c7824085292f7d21f1b00a5b9dc44152b495 XSIZE (open-vm-tools-2009.11.16-210370.tar.gz) = 3514530 a39f43b1b241daee8e1a12ca67ace65a echo x - open-vm-tools/pkg-descr sed 's/^X//' >open-vm-tools/pkg-descr << 'ea64d5364a985f50a3d17f3295dab104' XThe Open Virtual Machine Tools (open-vm-tools) are the open source Ximplementation of VMware Tools. They are a set of guest operating Xsystem virtualization components that enhance performance and user Xexperience of virtual machines. As virtualization technology rapidly Xbecomes mainstream, each virtualization solution provider implements Xtheir own set of tools and utilities to supplement the guest virtual Xmachine. However, most of the implementations are proprietary and Xare tied to a specific virtualization platform. X XThis port replaces the vmware guest ports and the binary only vmware Xtools ports in the ports tree. X XWWW: http://open-vm-tools.sourceforge.net ea64d5364a985f50a3d17f3295dab104 echo x - open-vm-tools/pkg-plist sed 's/^X//' >open-vm-tools/pkg-plist << '171d0e0dff7a07237cf38703130215f6' Xbin/vmware-checkvm Xbin/vmware-hgfsclient Xbin/vmware-rpctool Xbin/vmware-xferlogs Xbin/vmtoolsd Xbin/vmware-toolbox-cmd X%%FUSE%%bin/vmware-vmblock-fuse Xlib/open-vm-tools/plugins/vmsvc/libguestInfo.so Xlib/open-vm-tools/plugins/vmsvc/libpowerOps.so Xlib/open-vm-tools/plugins/vmsvc/libtimeSync.so Xlib/open-vm-tools/plugins/vmsvc/libvmbackup.so Xlib/open-vm-tools/plugins/common/libhgfsServer.so Xlib/open-vm-tools/plugins/common/libhgfsServer.la Xlib/open-vm-tools/plugins/common/libvix.so Xlib/open-vm-tools/plugins/common/libvix.la X%%X11%%lib/open-vm-tools/plugins/vmusr/libresolutionSet.so X%%X11%%lib/open-vm-tools/plugins/vmusr/libvixUser.so Xlib/libvmtools.a Xlib/libvmtools.la Xlib/libvmtools.so Xlib/libvmtools.so.0 Xlib/libguestlib.a Xlib/libguestlib.la Xlib/libguestlib.so Xlib/libguestlib.so.0 Xlib/pkgconfig/vmguestlib.pc Xlib/vmware-tools/modules/drivers/linker.hints Xlib/vmware-tools/modules/drivers/vmblock.ko Xlib/vmware-tools/modules/drivers/vmhgfs.ko Xlib/vmware-tools/modules/drivers/vmmemctl.ko Xlib/vmware-tools/modules/drivers/vmxnet.ko Xshare/open-vm-tools/tests/libtestDebug.so Xshare/open-vm-tools/tests/libtestPlugin.so Xinclude/vmGuestLib/includeCheck.h Xinclude/vmGuestLib/vmGuestLib.h Xinclude/vmGuestLib/vmSessionId.h Xinclude/vmGuestLib/vm_basic_types.h X@exec mkdir -p %D/lib/vmware-tools/modules/input Xsbin/mount_vmhgfs X%%X11%%bin/vmware-toolbox X%%X11%%bin/vmware-user X%%X11%%bin/vmware-user-suid-wrapper X%%X11%%share/applications/vmware-user.desktop Xshare/vmware-tools/poweroff-vm-default Xshare/vmware-tools/poweron-vm-default Xshare/vmware-tools/resume-vm-default Xshare/vmware-tools/suspend-vm-default Xshare/vmware-tools/vm-support X@exec kldxref %D/lib/vmware-tools/modules/drivers 2>/dev/null || true X@unexec if test -f %D/lib/vmware-tools/modules/drivers/linker.hints; then rm -f %D/lib/vmware-tools/modules/drivers/linker.hints; fi X@unexec if test -f %D/share/vmware-tools/tools.conf; then rm -f %D/share/vmware-tools/tools.conf; fi X@unexec if test -h %D/etc/vmware-tools/plugins; then rm -f %D/etc/vmware-tools/plugins; fi X@dirrmtry lib/vmware-tools/modules/drivers X@dirrmtry lib/vmware-tools/modules/input X@dirrmtry lib/vmware-tools/modules X@dirrmtry lib/vmware-tools X@dirrmtry etc/vmware-tools X@dirrmtry share/open-vm-tools/tests X@dirrmtry share/open-vm-tools X@dirrmtry share/vmware-tools X@dirrmtry lib/pkgconfig X%%X11%%@dirrmtry share/applications X@dirrm lib/open-vm-tools/plugins/common X@dirrm lib/open-vm-tools/plugins/vmsvc X%%X11%%@dirrm lib/open-vm-tools/plugins/vmusr X@dirrm lib/open-vm-tools/plugins X@dirrm lib/open-vm-tools X@dirrm include/vmGuestLib 171d0e0dff7a07237cf38703130215f6 exit >Release-Note: >Audit-Trail: >Unformatted: