aboutsummaryrefslogtreecommitdiff
path: root/emulators/vmware-guestd4
diff options
context:
space:
mode:
authorMakoto Matsushita <matusita@FreeBSD.org>2006-05-31 06:28:01 +0000
committerMakoto Matsushita <matusita@FreeBSD.org>2006-05-31 06:28:01 +0000
commit821cfa67d7e3c6b580b69efbde612ae350b56909 (patch)
tree5f8034dcf09dae9f8267077b3ead7c3caf591d94 /emulators/vmware-guestd4
parent50eb0a3c0fc6c87f24f1d1777fcae3c6e13e54ed (diff)
downloadports-821cfa67d7e3c6b580b69efbde612ae350b56909.tar.gz
ports-821cfa67d7e3c6b580b69efbde612ae350b56909.zip
Notes
Diffstat (limited to 'emulators/vmware-guestd4')
-rw-r--r--emulators/vmware-guestd4/Makefile11
-rw-r--r--emulators/vmware-guestd4/files/vmware-guestd.sh49
-rw-r--r--emulators/vmware-guestd4/pkg-plist1
3 files changed, 5 insertions, 56 deletions
diff --git a/emulators/vmware-guestd4/Makefile b/emulators/vmware-guestd4/Makefile
index 1086e8532f43..f3795778c479 100644
--- a/emulators/vmware-guestd4/Makefile
+++ b/emulators/vmware-guestd4/Makefile
@@ -25,9 +25,7 @@ IGNOREFILES= ${DISTFILES}
WRKSRC= ${WRKDIR}/vmware-tools-distrib
ONLY_FOR_ARCHS= i386
-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
@@ -149,15 +147,16 @@ 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}/sbin/vmware-guestd ${PREFIX}/sbin
${INSTALL_PROGRAM} ${WRKSRC}/sbin/vmware-checkvm ${PREFIX}/sbin
.if defined(WITH_VMWARE_VMMEMCTL)
${MKDIR} ${VMWARE_KMODDIR}
${INSTALL_PROGRAM} ${WRKDIR}/vmmemctl-only/vmmemctl.ko ${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}
-${LOCALBASE}/sbin/vmware-guestd --cmd toolinstall.end
.endif
${MKDIR} ${PREFIX}/share/vmware-tools
diff --git a/emulators/vmware-guestd4/files/vmware-guestd.sh b/emulators/vmware-guestd4/files/vmware-guestd.sh
deleted file mode 100644
index 4f5072ce1f41..000000000000
--- a/emulators/vmware-guestd4/files/vmware-guestd.sh
+++ /dev/null
@@ -1,49 +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_kmod_start()
-{
- echo 'Loading vmmemctl kernel module.'
- kldload ${PREFIX}/lib/vmware-tools/modules/vmmemctl.ko >/dev/null 2>&1
-}
-
-# VMware kernel modules
-name="vmware_guest_kmod"
-rcvar=`set_rcvar`
-start_precmd="${checkvm_cmd}"
-start_cmd="vmware_guest_kmod_start"
-stop_precmd="${checkvm_cmd}"
-stop_cmd=":"
-
-load_rc_config $name
-[ -z "$vmware_guest_kmod_enable" ] && vmware_guest_kmod_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-guestd4/pkg-plist b/emulators/vmware-guestd4/pkg-plist
index 13209e0bc574..7792b5a8fef9 100644
--- a/emulators/vmware-guestd4/pkg-plist
+++ b/emulators/vmware-guestd4/pkg-plist
@@ -1,6 +1,5 @@
sbin/vmware-checkvm
sbin/vmware-guestd
-etc/rc.d/vmware-guestd.sh
%%VMWARE_VMMEMCTL:%%lib/vmware-tools/modules/vmmemctl.ko
%%VMWARE_VMMEMCTL:%%@dirrmtry lib/vmware-tools/modules
%%VMWARE_VMMEMCTL:%%@dirrmtry lib/vmware-tools