diff options
Diffstat (limited to 'sci-biology/foldingathome/files/folding-init.d-r3')
-rw-r--r-- | sci-biology/foldingathome/files/folding-init.d-r3 | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/sci-biology/foldingathome/files/folding-init.d-r3 b/sci-biology/foldingathome/files/folding-init.d-r3 new file mode 100644 index 000000000000..eaeda24dad93 --- /dev/null +++ b/sci-biology/foldingathome/files/folding-init.d-r3 @@ -0,0 +1,25 @@ +#!/sbin/runscript +# Copyright 1999-2003 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sci-biology/foldingathome/files/folding-init.d-r3,v 1.1 2004/12/23 18:37:10 ribosome Exp $ + +start() { + ebegin "Starting Folding@Home" + for (($CPU; CPU != 0; CPU--)) + do + cd /opt/foldingathome/client${CPU}/ + nice -n 20 su foldingathome -c "/opt/foldingathome/client${CPU}/foldingathome ${FOLD_OPTS}" &>/dev/null & + done + eend $? +} + +stop() { + ebegin "Stopping Folding@Home" + for I in FahCore*.exe + do + killall -q $I >/dev/null + done + killall foldingathome >/dev/null + eend $? +} + |