diff options
author | Mike Auty <ikelos@gentoo.org> | 2008-11-09 20:23:55 +0000 |
---|---|---|
committer | Mike Auty <ikelos@gentoo.org> | 2008-11-09 20:23:55 +0000 |
commit | ab2f748503a802c23d050ff570fe447bc5eb260f (patch) | |
tree | 93bcc5d1ab8dbb9a37c72b96df3e6b6386d34dca /app-emulation/vmware-player/files/vmware-player-2.5.rc | |
parent | Add in vmware-modules-1.0.0.23 for vmware-workstation-6.5 and vmware-player-2.5. (diff) | |
download | historical-ab2f748503a802c23d050ff570fe447bc5eb260f.tar.gz historical-ab2f748503a802c23d050ff570fe447bc5eb260f.tar.bz2 historical-ab2f748503a802c23d050ff570fe447bc5eb260f.zip |
Bump to 1.0.9 and introduce 2.5.0 for bug 245941.
Package-Manager: portage-2.2_rc13/cvs/Linux 2.6.27-gentoo-r1 i686
Diffstat (limited to 'app-emulation/vmware-player/files/vmware-player-2.5.rc')
-rw-r--r-- | app-emulation/vmware-player/files/vmware-player-2.5.rc | 74 |
1 files changed, 74 insertions, 0 deletions
diff --git a/app-emulation/vmware-player/files/vmware-player-2.5.rc b/app-emulation/vmware-player/files/vmware-player-2.5.rc new file mode 100644 index 000000000000..6edba1627c73 --- /dev/null +++ b/app-emulation/vmware-player/files/vmware-player-2.5.rc @@ -0,0 +1,74 @@ +#!/sbin/runscript +# Copyright 1999-2004 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/app-emulation/vmware-player/files/vmware-player-2.5.rc,v 1.1 2008/11/09 20:23:55 ikelos Exp $ + +depend() { + need localmount + use logger net hald + after samba +} + +vmware_prettify() { + # Yea, the code is ugly but the output is pretty + state=$1 + waserror=0 + msgtype=0 + while read line + do + [ "${line}" = "" ] && continue + if [ ${msgtype} -le 0 ] + then + if [ ${msgtype} -eq -1 ] + then + ewarn ${line} + continue + fi + case ${line} in + *:*) + einfon ${line} + echo + eend 0 + msgtype=1;; + *) + ewarn ${line} + msgtype=-1 + waserror=1;; + esac + continue + fi + + # Strip out anything after the <esc> code + message=`echo ${line} | sed -e "s/^\(.*\).*$/\1/"` + einfon " ${message}" + echo + + echo ${line} | grep -q done + status=$? + eend ${status} + + if [ ${status} -eq 0 ] + then + logger -p local0.err -t vmware-${state} "${line}" + waserror=${status} + fi + done + if [ "${msgtype}" = "-1" ] + then + eend 1 "VMware is not properly configured! See above." + fi + return ${waserror} +} + +start() { + test -x /etc/vmware/init.d/vmware || \ + eend 1 "vmware init script not found. Aborting" || return 1 + + /etc/vmware/init.d/vmware start | vmware_prettify start + return $? +} + +stop() { + /etc/vmware/init.d/vmware stop | vmware_prettify stop + return $? +} |