summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSteve Arnold <nerdboy@gentoo.org>2004-11-10 06:13:14 +0000
committerSteve Arnold <nerdboy@gentoo.org>2004-11-10 06:13:14 +0000
commit4c69b50e8e7b480b389bd12ad6be240b65d24907 (patch)
tree8cde515b614e72254ca9cdf7ddbe1b9f0594ce8c /app-sci
parentamd64 stable for gallery (Manifest recommit) (diff)
downloadgentoo-2-4c69b50e8e7b480b389bd12ad6be240b65d24907.tar.gz
gentoo-2-4c69b50e8e7b480b389bd12ad6be240b65d24907.tar.bz2
gentoo-2-4c69b50e8e7b480b389bd12ad6be240b65d24907.zip
bumped to current version (bug 60318)
Diffstat (limited to 'app-sci')
-rw-r--r--app-sci/foldingathome/ChangeLog10
-rw-r--r--app-sci/foldingathome/Manifest22
-rw-r--r--app-sci/foldingathome/files/copy_client_config29
-rw-r--r--app-sci/foldingathome/files/digest-foldingathome-5.0.21
-rw-r--r--app-sci/foldingathome/files/folding-conf.d-r129
-rw-r--r--app-sci/foldingathome/files/folding-init.d-r438
-rw-r--r--app-sci/foldingathome/files/initfolding-r26
-rw-r--r--app-sci/foldingathome/foldingathome-5.0.2.ebuild79
8 files changed, 205 insertions, 9 deletions
diff --git a/app-sci/foldingathome/ChangeLog b/app-sci/foldingathome/ChangeLog
index 0db632f6b9f7..4540fa97c79b 100644
--- a/app-sci/foldingathome/ChangeLog
+++ b/app-sci/foldingathome/ChangeLog
@@ -1,6 +1,14 @@
# ChangeLog for app-sci/foldingathome
# Copyright 2002-2004 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-sci/foldingathome/ChangeLog,v 1.15 2004/06/24 21:58:40 agriffis Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-sci/foldingathome/ChangeLog,v 1.16 2004/11/10 06:13:14 nerdboy Exp $
+
+*foldingathome-5.0.2 (09 Nov 2004)
+
+ 09 Nov 2004; Steve Arnold <nerdboy@gentoo.org> +files/copy_client_config,
+ +files/folding-conf.d-r1, +files/folding-init.d-r4, +files/initfolding-r2,
+ +foldingathome-5.0.2.ebuild:
+ bumped to current version (bug 60318) with ebuild from Gregory P. Smith
+ <greg-gentoo@electricrain.com>. Gentoo team config.
12 Jun 2004; Danny van Dyk <kugelfang@gentoo.org>
foldingathome-4.0.0-r2.ebuild:
diff --git a/app-sci/foldingathome/Manifest b/app-sci/foldingathome/Manifest
index 3c5e72eb40ad..9b76623b4aa6 100644
--- a/app-sci/foldingathome/Manifest
+++ b/app-sci/foldingathome/Manifest
@@ -1,16 +1,22 @@
-MD5 ba1fe5c75666b9f4372ffcaa11de9a2a ChangeLog 2728
+MD5 75a3da476a2a470e75e6bafbecaddcd1 ChangeLog 3078
+MD5 2968925d8b7b9ae2a4dc53dcd086f016 foldingathome-4.0.0-r1.ebuild 1896
MD5 b0af599249fff5886fef0f3856b09eaa foldingathome-4.0.0-r2.ebuild 1903
-MD5 8c623e53daafa025137077c6b65815bd metadata.xml 156
MD5 6f2db7b7565ac75c66f6db8922e3f65c foldingathome-4.0.0.ebuild 1447
-MD5 2968925d8b7b9ae2a4dc53dcd086f016 foldingathome-4.0.0-r1.ebuild 1896
-MD5 a586f7af900f3c15982e59730e7e082a files/folding-conf.d 1125
+MD5 8c623e53daafa025137077c6b65815bd metadata.xml 156
+MD5 0e29ef8859474457d4db836cad631736 foldingathome-5.0.2.ebuild 1895
+MD5 f3a9e0a439c14bd3d328cea6e3af1540 files/initfolding-r2 150
+MD5 6c633c6cc20e087d9da4585c5d9563dc files/digest-foldingathome-4.0.0 66
+MD5 6c633c6cc20e087d9da4585c5d9563dc files/digest-foldingathome-4.0.0-r1 66
MD5 6c633c6cc20e087d9da4585c5d9563dc files/digest-foldingathome-4.0.0-r2 66
+MD5 a586f7af900f3c15982e59730e7e082a files/folding-conf.d 1125
MD5 9c9e4e6f2559cf1191b842ad06da6689 files/folding-init.d 535
-MD5 84d1c6aa59e3e57a12742c5e1224050f files/folding-init.d-r3 637
MD5 f0462622685d1daf28447505a5f6cc85 files/folding-init.d-r1 738
+MD5 4a310628702e01fd17f5e7a9b8ec10f8 files/folding-init.d-r2 699
+MD5 84d1c6aa59e3e57a12742c5e1224050f files/folding-init.d-r3 637
MD5 aec1f2de50cf95bf1797d61ae94b3b04 files/folding.sh 88
MD5 91f88a421f87928d798002ede77fa8f9 files/initfolding 80
-MD5 6c633c6cc20e087d9da4585c5d9563dc files/digest-foldingathome-4.0.0 66
-MD5 6c633c6cc20e087d9da4585c5d9563dc files/digest-foldingathome-4.0.0-r1 66
-MD5 4a310628702e01fd17f5e7a9b8ec10f8 files/folding-init.d-r2 699
MD5 9c93f287339458f575ee4c5d20fffdfe files/initfolding-r1 656
+MD5 cd07557b5a0c08853562d0a5ae204d78 files/copy_client_config 756
+MD5 3174784abb8ed1da2fc846d722aeffe5 files/folding-conf.d-r1 1172
+MD5 9e3c2368225e63404563318c4595de55 files/folding-init.d-r4 1045
+MD5 2f181dd626be0626fc9000536fd0d4c4 files/digest-foldingathome-5.0.2 61
diff --git a/app-sci/foldingathome/files/copy_client_config b/app-sci/foldingathome/files/copy_client_config
new file mode 100644
index 000000000000..f12d1258a1b4
--- /dev/null
+++ b/app-sci/foldingathome/files/copy_client_config
@@ -0,0 +1,29 @@
+#!/usr/bin/env python
+
+import shutil, sys, os
+from ConfigParser import ConfigParser
+
+GENTOO_TEAM = 11298
+
+if not os.path.isfile("/opt/foldingathome/client1/client.cfg"):
+ print "Folding@Home installation hasn't been configured yet"
+ sys.exit(1)
+
+clientnum = (1, 2, 3, 4, 5, 6, 7, 8)
+
+cfg = ConfigParser()
+cfg.read("/opt/foldingathome/client1/client.cfg")
+
+# if the user didn't chose a team at setup time put them on the gentoo team
+if cfg.get("settings", 'team') == '0':
+ cfg.set("settings", 'team', GENTOO_TEAM)
+
+for i in clientnum:
+ cfgName = "/opt/foldingathome/client%d/client.cfg" % (i)
+ shutil.copyfile("/opt/foldingathome/client1/client.cfg", cfgName)
+
+ cfg.set("settings", 'machineid', i)
+
+ cfgFile = open(cfgName, "w")
+ cfg.write(cfgFile)
+
diff --git a/app-sci/foldingathome/files/digest-foldingathome-5.0.2 b/app-sci/foldingathome/files/digest-foldingathome-5.0.2
new file mode 100644
index 000000000000..44de62a3f7fd
--- /dev/null
+++ b/app-sci/foldingathome/files/digest-foldingathome-5.0.2
@@ -0,0 +1 @@
+MD5 4855e808fb94e6d2c5fde345aea0cdc3 FAH502-Linux.exe 249236
diff --git a/app-sci/foldingathome/files/folding-conf.d-r1 b/app-sci/foldingathome/files/folding-conf.d-r1
new file mode 100644
index 000000000000..ad4839b9d2af
--- /dev/null
+++ b/app-sci/foldingathome/files/folding-conf.d-r1
@@ -0,0 +1,29 @@
+# Config file for /etc/init.d/foldingathome
+#
+# The f@h client configuration can be found in /opt/foldingathome/client1/client.cfg
+# Run /opt/foldingathome/initfolding to reconfigure that.
+#
+# Enter options here to be passed to the Folding client:
+#
+# -oneunit Instruct the client to quit following the completion of one work unit.
+# -verbosity x Sets the output level, from 1 to 9 (max). The default is 3
+# -forceasm Force core assembly optimizations to be used if available
+# -advmethods Request to be assigned any new Cores or work units.
+#
+# A full listing of options can be found here:
+# http://www.stanford.edu/group/pandegroup/folding/console-userguide.html
+# But use of other options are not recommended when using the Folding client
+# as a service.
+#
+#FOLD_OPTS="-advmethods"
+
+# Number of clients to run
+#
+# Folding@Home isn't multithreaded, so if you're running multiple CPU's
+# you will need to run a client to run for each of your CPU's in order
+# to achieve the best performance for Folding@Home. Up to a maximum of 8.
+# Ex. A dual CPU system would use CPU=2. The init script has code to
+# determine how many CPUs you have if you set CPU=0.
+#
+CPU=0
+
diff --git a/app-sci/foldingathome/files/folding-init.d-r4 b/app-sci/foldingathome/files/folding-init.d-r4
new file mode 100644
index 000000000000..5ea5371cdb8c
--- /dev/null
+++ b/app-sci/foldingathome/files/folding-init.d-r4
@@ -0,0 +1,38 @@
+#!/sbin/runscript
+# Copyright 1999-2004 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-sci/foldingathome/files/folding-init.d-r4,v 1.1 2004/11/10 06:13:14 nerdboy Exp $
+
+start() {
+ ebegin "Starting Folding@Home"
+ if [ $CPU = 0 -a -r /proc/cpuinfo ]; then
+ CPU=`grep processor </proc/cpuinfo | wc -l`
+ fi
+ su foldingathome -c /opt/foldingathome/copy_client_config
+ 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"
+ if [ $CPU = 0 -a -r /proc/cpuinfo ]; then
+ CPU=`grep processor </proc/cpuinfo | wc -l`
+ fi
+ for (($CPU; CPU != 0; CPU--))
+ do
+ cd /opt/foldingathome/client${CPU}/
+ for I in FahCore*.exe
+ do
+ killall -q $I >/dev/null
+ done
+ done
+ # killing the Core(s) above shuts the top level foldingathome process
+ # down for us; don't kill it here.
+ #killall foldingathome >/dev/null
+ eend $?
+}
+
diff --git a/app-sci/foldingathome/files/initfolding-r2 b/app-sci/foldingathome/files/initfolding-r2
new file mode 100644
index 000000000000..1e39fa32359d
--- /dev/null
+++ b/app-sci/foldingathome/files/initfolding-r2
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+cd /opt/foldingathome/client1
+/opt/foldingathome/client1/foldingathome -configonly
+/bin/chown -R foldingathome:nogroup /opt/foldingathome
+
diff --git a/app-sci/foldingathome/foldingathome-5.0.2.ebuild b/app-sci/foldingathome/foldingathome-5.0.2.ebuild
new file mode 100644
index 000000000000..3375c2391af0
--- /dev/null
+++ b/app-sci/foldingathome/foldingathome-5.0.2.ebuild
@@ -0,0 +1,79 @@
+# Copyright 1999-2004 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-sci/foldingathome/foldingathome-5.0.2.ebuild,v 1.1 2004/11/10 06:13:14 nerdboy Exp $
+
+# no version number on this install dir since upgrades will be using same dir
+# (data will be stored here too)
+I="/opt/foldingathome"
+
+inherit eutils
+
+DESCRIPTION="Help simulate protein folding at home"
+HOMEPAGE="http://folding.stanford.edu/"
+SRC_URI="http://www.stanford.edu/group/pandegroup/release/FAH502-Linux.exe"
+RESTRICT="nomirror"
+
+SLOT="0"
+IUSE=""
+LICENSE="as-is"
+KEYWORDS="~x86 ~amd64"
+
+DEPEND=">=sys-apps/baselayout-1.8.0
+ >=sys-libs/glibc-2.3.0
+ amd64? ( app-emulation/emul-linux-x86-baselibs )"
+
+S="${WORKDIR}"
+
+src_unpack() {
+ cp "${DISTDIR}/${A}" ${PN}
+}
+
+src_install() {
+ exeinto ${I}
+ newexe ${FILESDIR}/initfolding-r2 initfolding
+ newexe ${FILESDIR}/copy_client_config copy_client_config
+
+ # Clients
+ exeinto ${I}/client1
+ doexe foldingathome
+ exeinto ${I}/client2
+ doexe foldingathome
+ exeinto ${I}/client3
+ doexe foldingathome
+ exeinto ${I}/client4
+ doexe foldingathome
+ exeinto ${I}/client5
+ doexe foldingathome
+ exeinto ${I}/client6
+ doexe foldingathome
+ exeinto ${I}/client7
+ doexe foldingathome
+ exeinto ${I}/client8
+ doexe foldingathome
+ exeinto /etc/init.d
+ newexe ${FILESDIR}/folding-init.d-r4 foldingathome
+
+ insinto /etc/conf.d
+ newins ${FILESDIR}/folding-conf.d-r1 foldingathome
+}
+
+pkg_preinst() {
+ # the bash shell is important for "su -c" in init script
+ enewuser foldingathome -1 /bin/bash /opt/foldingathome
+}
+
+pkg_postinst() {
+ chown -R foldingathome:nogroup /opt/foldingathome
+ einfo "To run Folding@home in the background at boot:"
+ einfo " rc-update add foldingathome default"
+ einfo ""
+ einfo "Please run ${I}/initfolding to configure your client"
+ einfo "and edit /etc/conf.d/foldingathome for options"
+ einfo ""
+}
+
+pkg_postrm() {
+ einfo "Folding@home data files were not removed."
+ einfo " Remove them manually from ${I}"
+ einfo ""
+}