Gentoo Archives: gentoo-commits

From: Tomas Chvatal <scarabeus@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/sci:master commit in: sci-misc/boinc-bin/files/, sci-misc/boinc-bin/
Date: Tue, 31 May 2011 10:29:24
Message-Id: 892c576874fbca764ac4b91a94eb49fa36856167.scarabeus@gentoo
1 commit: 892c576874fbca764ac4b91a94eb49fa36856167
2 Author: Tomas Chvatal <scarabeus <AT> gentoo <DOT> org>
3 AuthorDate: Tue May 31 10:29:09 2011 +0000
4 Commit: Tomas Chvatal <scarabeus <AT> gentoo <DOT> org>
5 CommitDate: Tue May 31 10:29:09 2011 +0000
6 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/sci.git;a=commit;h=892c5768
7
8 [sci-misc/boinc-bin] Remove obsolete package version.
9
10 ---
11 sci-misc/boinc-bin/ChangeLog | 33 --------
12 sci-misc/boinc-bin/boinc-bin-6.4.5.ebuild | 125 -----------------------------
13 sci-misc/boinc-bin/files/boinc.conf | 28 -------
14 sci-misc/boinc-bin/files/boinc.init | 116 --------------------------
15 sci-misc/boinc-bin/metadata.xml | 16 ----
16 5 files changed, 0 insertions(+), 318 deletions(-)
17
18 diff --git a/sci-misc/boinc-bin/ChangeLog b/sci-misc/boinc-bin/ChangeLog
19 deleted file mode 100644
20 index 9063928..0000000
21 --- a/sci-misc/boinc-bin/ChangeLog
22 +++ /dev/null
23 @@ -1,33 +0,0 @@
24 -# ChangeLog for sci-misc/boinc-bin
25 -# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
26 -# $Header: $
27 -
28 - 14 Mar 2011; Justin Lecher <jlec@g.o> boinc-bin-6.4.5.ebuild:
29 - Moved media-libs/jpeg -> virtual/jpeg
30 -
31 - 23 Jan 2009; Tomas Chvatal <scarabeus@g.o> files/boinc.init,
32 - boinc-bin-6.4.5.ebuild:
33 - cuda working.
34 -
35 - 22 Jan 2009; Tomas Chvatal <scarabeus@g.o> -boinc-bin-6.5.0.ebuild:
36 - Dont bother with prereleases (waste of time).
37 -
38 - 22 Jan 2009; Tomas Chvatal <scarabeus@g.o> files/boinc.init,
39 - boinc-bin-6.4.5.ebuild, boinc-bin-6.5.0.ebuild:
40 - Moar init.d fixups.
41 -
42 - 22 Jan 2009; Tomas Chvatal <scarabeus@g.o> files/boinc.conf,
43 - files/boinc.init, boinc-bin-6.4.5.ebuild, boinc-bin-6.5.0.ebuild:
44 - Update initscripts and ebuilds a bit.
45 -
46 -*boinc-bin-6.4.5 (21 Jan 2009)
47 -
48 - 21 Jan 2009; Tomas Chvatal <scarabeus@g.o> +boinc-bin-6.5.0.ebuild:
49 - Add normal binary release
50 -
51 -*boinc-bin-6.5.0 (21 Jan 2009)
52 -
53 - 21 Jan 2009; Tomas Chvatal <scarabeus@g.o> +files/boinc.conf,
54 - +files/boinc.init, +metadata.xml, +boinc-bin-6.5.0.ebuild:
55 - Add binary prerelease.
56 -
57
58 diff --git a/sci-misc/boinc-bin/boinc-bin-6.4.5.ebuild b/sci-misc/boinc-bin/boinc-bin-6.4.5.ebuild
59 deleted file mode 100644
60 index ad0778a..0000000
61 --- a/sci-misc/boinc-bin/boinc-bin-6.4.5.ebuild
62 +++ /dev/null
63 @@ -1,125 +0,0 @@
64 -# Copyright 1999-2011 Gentoo Foundation
65 -# Distributed under the terms of the GNU General Public License v2
66 -# $Header: $
67 -
68 -#
69 -# Don't forget to keep things in sync with normal boinc package!
70 -#
71 -
72 -EAPI="2"
73 -
74 -inherit eutils
75 -
76 -MY_PN="${PN//-bin/}"
77 -MY_PV="${PV//./_}"
78 -DESCRIPTION="The Berkeley Open Infrastructure for Network Computing"
79 -HOMEPAGE="http://boinc.ssl.berkeley.edu/"
80 -SRC_URI="
81 - amd64? ( http://${MY_PN}dl.ssl.berkeley.edu/dl/${MY_PN}_${PV}_x86_64-pc-linux-gnu.sh )
82 - x86? ( http://${MY_PN}dl.ssl.berkeley.edu/dl/${MY_PN}_${PV}_i686-pc-linux-gnu.sh )
83 - "
84 -
85 -LICENSE="LGPL-2.1"
86 -SLOT="0"
87 -KEYWORDS="-* ~amd64 ~x86"
88 -IUSE="X cuda"
89 -
90 -DEPEND=""
91 -RDEPEND="
92 - !sci-misc/boinc
93 - app-misc/ca-certificates
94 - dev-libs/openssl
95 - net-misc/curl
96 - sys-apps/util-linux
97 - sys-libs/zlib
98 - cuda? (
99 - >=dev-util/nvidia-cuda-toolkit-2.1
100 - >=x11-drivers/nvidia-drivers-180.22
101 - )
102 - X? (
103 - media-libs/freeglut
104 - virtual/jpeg
105 - x11-libs/wxGTK:2.8[X,opengl]
106 - )
107 - "
108 -
109 -S="${WORKDIR}"/BOINC
110 -
111 -LANGS="ar be bg ca cs da de el en_US es eu fi fr hr hu it ja lt lv nb nl pl pt
112 -pt_BR ro ru sk sl sv_SE tr uk zh_CN zh_TW"
113 -for LNG in ${LANGS}; do
114 - IUSE="${IUSE} linguas_${LNG}"
115 -done
116 -
117 -src_unpack() {
118 - local target
119 - use x86 && target="i686" || target="x86_64"
120 - cp "${DISTDIR}"/${MY_PN}_${PV}_${target}-pc-linux-gnu.sh "${WORKDIR}" \
121 - || die "failed to prepare binary"
122 - cd "${WORKDIR}"
123 - sh ${MY_PN}_${PV}_${target}-pc-linux-gnu.sh &> /dev/null # annoying messages
124 -}
125 -
126 -src_install() {
127 - newinitd "${FILESDIR}"/${MY_PN}.init ${MY_PN}
128 - newconfd "${FILESDIR}"/${MY_PN}.conf ${MY_PN}
129 - # fancy X stuff
130 - if use X; then
131 - # icon
132 - newicon "${S}"/${MY_PN}mgr.48x48.png ${MY_PN}.png
133 - # desktop
134 - make_desktop_entry /opt/bin/boinc "${MY_PN}" ${MY_PN} "Education;Science" /var/lib/${MY_PN}
135 - fi
136 - # use correct path in scripts
137 - sed -i \
138 - -e "s:${S}:/opt/${MY_PN}/:g" \
139 - -e "s:./${MY_PN}mgr:/opt/${MY_PN}/${MY_PN}mgr:g" \
140 - run_manager || die "sed run_manager failed"
141 - # install binaries
142 - exeopts -m0755
143 - exeinto /opt/${MY_PN}
144 - doexe "${S}"/{${MY_PN},${MY_PN}cmd,${MY_PN}mgr,run_manager}
145 - fowners 0:${MY_PN} /opt/${MY_PN}/{${MY_PN},${MY_PN}cmd,${MY_PN}mgr,run_manager}
146 - # symlink the important ones to the /opt/bin/
147 - dosym /opt/${MY_PN}/run_manager /opt/bin/boinc
148 - # locale
149 - insopts -m0644
150 - insinto /opt/${MY_PN}/locale
151 - cd "${S}"/locale/
152 - for LNG in ${LINGUAS}; do
153 - doins -r "${LNG}"
154 - done
155 - # certificates
156 - dosym /etc/ssl/certs/ca-certificates.crt /opt/${MY_PN}/ca-bundle.crt
157 - # cuda
158 - use cuda && dosym /opt/cuda/lib/libcudart.so /opt/${MY_PN}/libcudart.so
159 -}
160 -
161 -pkg_setup() {
162 - enewgroup ${MY_PN}
163 - if use cuda; then
164 - enewuser ${MY_PN} -1 -1 /var/lib/${MY_PN} "${MY_PN},video"
165 - else
166 - enewuser ${MY_PN} -1 -1 /var/lib/${MY_PN} "${MY_PN}"
167 - fi
168 -}
169 -
170 -pkg_postinst() {
171 - echo
172 - elog "You are using the binary distributed version."
173 - elog "The manager can be found at /opt/bin/${MY_PN}"
174 - elog
175 - elog "You need to attach to a project to do anything useful with ${MY_PN}."
176 - elog "You can do this by running /etc/init.d/${MY_PN} attach"
177 - elog "The howto for configuration is located at:"
178 - elog "http://${MY_PN}.berkeley.edu/anonymous_platform.php"
179 - elog
180 - # Add warning about the new password for the client, bug 121896.
181 - elog "If you need to use the graphical client the password is in:"
182 - elog "/var/lib/${MY_PN}/gui_rpc_auth.cfg"
183 - elog "Where /var/lib/ is default RUNTIMEDIR, that can be changed in:"
184 - elog "/etc/conf.d/${MY_PN}"
185 - elog "You should change this to something more memorable (can be even blank)."
186 - elog
187 - elog "Remember to launch init script before using manager. Or changing the password."
188 -}
189
190 diff --git a/sci-misc/boinc-bin/files/boinc.conf b/sci-misc/boinc-bin/files/boinc.conf
191 deleted file mode 100644
192 index 884189a..0000000
193 --- a/sci-misc/boinc-bin/files/boinc.conf
194 +++ /dev/null
195 @@ -1,28 +0,0 @@
196 -# Config file for /etc/init.d/boinc
197 -
198 -# Owner of BOINC process (must be existing)
199 -USER="boinc"
200 -GROUP="boinc"
201 -
202 -# Directory with runtime data: Work units, project binaries, user info etc.
203 -RUNTIMEDIR="/var/lib/boinc"
204 -
205 -# Location of the boinc command line binary
206 -BOINCBIN="/opt/boinc/boinc"
207 -
208 -# Logfile (/dev/null for nowhere)
209 -LOGFILE="/var/log/boinc.log"
210 -
211 -# Allow remote gui RPC yes or no
212 -ALLOW_REMOTE_RPC="no"
213 -
214 -# nice level
215 -NICELEVEL="19"
216 -
217 -# scheduling parameters, arguments to chrt(1)
218 -SCHED_PARAM="--batch 0"
219 -
220 -# Relative CPU allocation for boinc user, default is 1024,
221 -# requires CONFIG_FAIR_GROUP_SCHED and CONFIG_USER_SCHED,
222 -# see /usr/src/linux/Documentation/scheduler/sched-design-CFS.txt
223 -CPU_SHARE="128"
224
225 diff --git a/sci-misc/boinc-bin/files/boinc.init b/sci-misc/boinc-bin/files/boinc.init
226 deleted file mode 100644
227 index 54812d1..0000000
228 --- a/sci-misc/boinc-bin/files/boinc.init
229 +++ /dev/null
230 @@ -1,116 +0,0 @@
231 -#!/sbin/runscript
232 -
233 -opts="${opts} attach"
234 -
235 -depend() {
236 - # we can use dns and net, but we can also in most cases live without them
237 - use dns net
238 -}
239 -
240 -create_work_directory() {
241 - if [[ ! -d $RUNTIMEDIR ]]; then
242 - einfo "Directory $RUNTIMEDIR not existing, creating now."
243 - mkdir $RUNTIMEDIR
244 - chown ${USER}:${GROUP} $RUNTIMEDIR
245 - if [[ ! -d $RUNTIMEDIR ]]; then
246 - eeror "Directory $RUNTIMEDIR could not be created!"
247 - return 1
248 - fi
249 - ln -s /etc/ssl/certs/ca-certificates.crt $RUNTIMEDIR/ca-bundle.crt
250 - fi
251 -}
252 -
253 -generate_logs() {
254 - if [[ ! -f $LOGFILE ]]; then
255 - einfo "No $LOGFILE around. Creating new..."
256 - einfo "For good log rotation is great tool app-admin/logrotate"
257 - touch $LOGFILE
258 - chown ${USER}:${GROUP} $LOGFILE
259 - fi
260 -}
261 -
262 -cuda_check() {
263 - if [[ -f /opt/boinc/libcudart.so ]]; then
264 - # user wanted cuda so lets enable it
265 - ln -s /opt/cuda/lib/libcudart.so $WORKDIR/libcudart.so
266 - fi
267 -}
268 -
269 -start() {
270 - ebegin "Starting BOINC"
271 -
272 - create_work_directory
273 -
274 - cd $RUNTIMEDIR
275 -
276 - if [[ ! -f lockfile ]]; then
277 - einfo "File $RUNTIMEDIR/lockfile does not exist, assuming first run."
278 - einfo "You need to setup an account on the BOINC project homepage beforehand!"
279 - einfo "Go to http://boinc.berkeley.edu/ and locate your project."
280 - einfo "Then either run /etc/init.d/boinc attach or connect with a gui client"
281 - einfo "and attach to a project with that."
282 - echo
283 - ewarn "Note that for attaching to some project you need your network up and running."
284 - ewarn "network is needed only for jobs fetching afterwards"
285 - fi
286 -
287 - generate_logs
288 -
289 - if [[ ${ALLOW_REMOTE_RPC} = "yes" ]]; then
290 - ARGS="${ARGS} -allow_remote_gui_rpc"
291 - fi
292 -
293 - # sys-apps/util-linux
294 - CHRT="/usr/bin/chrt ${SCHED_PARAM}"
295 -
296 - ${CHRT} start-stop-daemon \
297 - --quiet --start --chdir ${RUNTIMEDIR} \
298 - --exec ${BOINCBIN} --chuid ${USER}:${GROUP} \
299 - --background --stdout ${LOGFILE} --stderr ${LOGFILE} \
300 - --nicelevel ${NICELEVEL} -- ${ARGS}
301 -
302 - RESULT=$?
303 -
304 - if [ "${CPU_SHARE}" -a -d /sys/kernel/uids ]; then
305 - BUID=`id -u ${USER}`
306 - # It might take a moment for start-stop-daemon to chuid
307 - [[ -d /sys/kernel/uids/${BUID} ]] || sleep 5 # 5 was working always here
308 - if [[ -w /sys/kernel/uids/${BUID}/cpu_share ]]; then
309 - echo ${CPU_SHARE} > /sys/kernel/uids/${BUID}/cpu_share
310 - fi
311 - fi
312 -
313 - eend $RESULT
314 -}
315 -
316 -attach() {
317 - printf " Enter the Project URL: "
318 - read url
319 - printf " Enter your Account Key: "
320 - read key
321 -
322 - RC_QUIET_STDOUT="yes" svc_status
323 - if [[ $? = 1 ]]; then
324 - svc_start
325 - fi
326 - ebegin "Attaching to project"
327 - # we have to work in runtime directory
328 - cd $RUNTIMEDIR
329 - # boinc does not return 1 when it fails currently
330 - $BOINCBIN --attach_project $url $key &> /dev/null
331 - eend $?
332 -
333 - sleep 10
334 - tail $LOGFILE
335 -}
336 -
337 -stop() {
338 - ebegin "Stopping BOINC"
339 - start-stop-daemon --stop --retry 3 --quiet --exec $BOINCBIN
340 - eend $?
341 -}
342 -
343 -restart() {
344 - svc_stop
345 - svc_start
346 -}
347
348 diff --git a/sci-misc/boinc-bin/metadata.xml b/sci-misc/boinc-bin/metadata.xml
349 deleted file mode 100644
350 index 0316880..0000000
351 --- a/sci-misc/boinc-bin/metadata.xml
352 +++ /dev/null
353 @@ -1,16 +0,0 @@
354 -<?xml version="1.0" encoding="UTF-8"?>
355 -<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
356 -<pkgmetadata>
357 -<herd>sci</herd>
358 -<maintainer>
359 - <email>scarabeus@g.o</email>
360 - <name>Tomas Chvatal</name>
361 -</maintainer>
362 -<use>
363 - <flag name="cuda">
364 - Use nvidia cuda toolkit for speeding up computations.
365 - NOTE: works only for subset of nvidia graphic cards so make sure your card
366 - is supported before opening bug about it.
367 - </flag>
368 -</use>
369 -</pkgmetadata>