aboutsummaryrefslogtreecommitdiffstats
path: root/emulators/vmware-guestd6
diff options
context:
space:
mode:
authormatusita <matusita@FreeBSD.org>2006-05-31 14:28:01 +0800
committermatusita <matusita@FreeBSD.org>2006-05-31 14:28:01 +0800
commit330064cf49d3e78b2842552d145dccb039ec13b3 (patch)
tree71123ac77f8e4439a03f0582bb1b63e4c9b3a3a5 /emulators/vmware-guestd6
parent6fdfcb95ce9da2444a1cd4d0244135910054b4b3 (diff)
downloadfreebsd-ports-gnome-330064cf49d3e78b2842552d145dccb039ec13b3.tar.gz
freebsd-ports-gnome-330064cf49d3e78b2842552d145dccb039ec13b3.tar.zst
freebsd-ports-gnome-330064cf49d3e78b2842552d145dccb039ec13b3.zip
Follow the new world order: use 'USE_RC_ORDER=file.sh' feature.
- repocopy vmware-guestd.sh to vmware-guestd.sh.in (by portmgr) - remove vmware-guestd.sh - remove vmware-guestd.sh entry from pkg-plist - update Makefile It is intensional that I do NOT bump PORTREVISION by this commit, since any executable is not changed, and startup script itself is also NOT changed, only the filename is changed. I do not want to bother users to update their port by this non-functional change. If you have any reasonable reason to bump PORTREVISION, let me know, and I'll update the version asap.
Diffstat (limited to 'emulators/vmware-guestd6')
-rw-r--r--emulators/vmware-guestd6/Makefile11
-rw-r--r--emulators/vmware-guestd6/files/vmware-guestd.sh67
-rw-r--r--emulators/vmware-guestd6/pkg-plist1
3 files changed, 5 insertions, 74 deletions
diff --git a/emulators/vmware-guestd6/Makefile b/emulators/vmware-guestd6/Makefile
index 2bee7ea76104..c0362691e13e 100644
--- a/emulators/vmware-guestd6/Makefile
+++ b/emulators/vmware-guestd6/Makefile
@@ -25,9 +25,7 @@ IGNOREFILES= ${DISTFILES}
WRKSRC= ${WRKDIR}/vmware-tools-distrib
ONLY_FOR_ARCHS= i386 amd64
-USE_RC_SUBR= yes
-RC_SCRIPT= ${PREFIX}/etc/rc.d/vmware-guestd.sh
-RC_SCRIPTS_SUB= PREFIX=${PREFIX} RC_SUBR=${RC_SUBR}
+USE_RC_SUBR= vmware-guestd.sh
.if !defined(BATCH)
IS_INTERACTIVE= yes
.endif
@@ -226,6 +224,10 @@ do-build:
.endif
do-install:
+ @if [ -f ${PREFIX}/etc/rc.d/${USE_RC_SUBR} ]; then \
+ ${ECHO_CMD} "Remove old ${PREFIX}/etc/rc.d/${USE_RC_SUBR} before install."; \
+ exit 1; \
+ fi
${INSTALL_PROGRAM} ${WRKSRC}/lib/sbin${BITS}/vmware-guestd ${PREFIX}/sbin
${INSTALL_PROGRAM} ${WRKSRC}/lib/sbin${BITS}/vmware-checkvm ${PREFIX}/sbin
.if defined(WITH_VMWARE_VMMEMCTL)
@@ -236,9 +238,6 @@ do-install:
${MKDIR} ${VMWARE_KMODDIR}
${INSTALL_PROGRAM} ${WRKSRC}/lib/modules/binary/FreeBSD${VMWARE_VMXNET_PATH} ${VMWARE_KMODDIR}
.endif
- @${SED} ${RC_SCRIPTS_SUB:S/$/!g/:S/^/ -e s!%%/:S/=/%%!/} \
- ${FILESDIR}/vmware-guestd.sh > ${WRKDIR}/vmware-guestd.sh
- @${INSTALL_SCRIPT} ${WRKDIR}/vmware-guestd.sh ${RC_SCRIPT}
-${WRKSRC}/lib/sbin${BITS}/vmware-guestd --cmd toolinstall.end
${MKDIR} ${PREFIX}/share/vmware-tools
${LN} -sfh /usr/bin/true ${PREFIX}/share/vmware-tools/poweroff-vm-default
diff --git a/emulators/vmware-guestd6/files/vmware-guestd.sh b/emulators/vmware-guestd6/files/vmware-guestd.sh
deleted file mode 100644
index 158e88bf56bd..000000000000
--- a/emulators/vmware-guestd6/files/vmware-guestd.sh
+++ /dev/null
@@ -1,67 +0,0 @@
-#!/bin/sh
-#
-# $FreeBSD$
-#
-
-# PROVIDE: vmware-guestd
-# REQUIRE: DAEMON
-# BEFORE: LOGIN
-
-PREFIX=%%PREFIX%%
-. %%RC_SUBR%%
-
-# Global
-checkvm_cmd="${PREFIX}/sbin/vmware-checkvm > /dev/null"
-
-# Functions
-vmware_guest_vmmemctl_start()
-{
- echo 'Loading vmmemctl kernel module.'
- kldload ${PREFIX}/lib/vmware-tools/modules/vmmemctl.ko >/dev/null 2>&1
-}
-vmware_guest_vmxnet_start()
-{
- echo 'Loading vmxnet kernel module.'
- kldload ${PREFIX}/lib/vmware-tools/modules/vmxnet.ko >/dev/null 2>&1
-}
-
-# VMware kernel module: vmmemctl
-name="vmware_guest_vmmemctl"
-rcvar=`set_rcvar`
-start_precmd="${checkvm_cmd}"
-start_cmd="vmware_guest_vmmemctl_start"
-stop_precmd="${checkvm_cmd}"
-stop_cmd=":"
-
-load_rc_config $name
-[ -z "$vmware_guest_vmmemctl_enable" ] && vmware_guest_vmmemctl_enable="NO"
-[ -n "$vmware_guest_kmod_enable" ] && vmware_guest_vmmemctl_enable="$vmware_guest_kmod_enable"
-run_rc_command "$1"
-
-# VMware kernel module: vmxnet
-name="vmware_guest_vmxnet"
-rcvar=`set_rcvar`
-start_precmd="${checkvm_cmd}"
-start_cmd="vmware_guest_vmxnet_start"
-stop_precmd="${checkvm_cmd}"
-stop_cmd=":"
-
-load_rc_config $name
-[ -z "$vmware_guest_vmxnet_enable" ] && vmware_guest_vmxnet_enable="NO"
-run_rc_command "$1"
-
-# VMware guest daemon
-name="vmware_guestd"
-rcvar=`set_rcvar`
-start_precmd="${checkvm_cmd}"
-unset start_cmd
-stop_precmd="${checkvm_cmd}"
-unset stop_cmd
-command="${PREFIX}/sbin/vmware-guestd"
-command_args="--halt-command '/sbin/shutdown -p now' >/dev/null 2>&1"
-pidfile="/var/run/${name}.pid"
-
-load_rc_config $name
-[ -z "$vmware_guestd_enable" ] && vmware_guestd_enable="YES"
-[ -z "$vmware_guestd_flags" ] && vmware_guestd_flags="--background ${pidfile}"
-run_rc_command "$1"
diff --git a/emulators/vmware-guestd6/pkg-plist b/emulators/vmware-guestd6/pkg-plist
index 4f377fe95b86..7351cf0bff61 100644
--- a/emulators/vmware-guestd6/pkg-plist
+++ b/emulators/vmware-guestd6/pkg-plist
@@ -1,5 +1,4 @@
@unexec %D/etc/rc.d/vmware-guestd.sh forcestop 2>/dev/null || true
-etc/rc.d/vmware-guestd.sh
sbin/vmware-checkvm
sbin/vmware-guestd
%%VMWARE_VMMEMCTL:%%lib/vmware-tools/modules/vmmemctl.ko