From 5024a320b2e6c951d141d99a803347c6d94ab68877d468babb4407a1686f9327 Mon Sep 17 00:00:00 2001 From: Christian Wittmer Date: Thu, 2 Feb 2012 20:59:26 +0000 Subject: [PATCH 1/7] Accepting request 102548 from home:computersalat:branches:network fix for bnc#689499 OBS-URL: https://build.opensuse.org/request/show/102548 OBS-URL: https://build.opensuse.org/package/show/network/boinc-client?expand=0&rev=17 --- boinc-LC_MESSAGES.patch | 8 +- boinc-client-dynamic_buffers.patch | 4 +- boinc-client.changes | 18 +++ boinc-client.init | 216 +++++++++++++++++++++++++++++ boinc-client.spec | 131 ++++++++--------- boinc-completion.patch | 8 +- boinc-docbook2x.patch | 8 +- boinc-guirpcauth.patch | 8 +- boinc-init.patch | 29 ++-- boinc-logrotate | 48 +++---- boinc-manager | 10 ++ boinc-server.patch | 8 +- boincmanager | 32 ----- sysconfig.boinc-client | 81 ++++++----- 14 files changed, 418 insertions(+), 191 deletions(-) create mode 100644 boinc-client.init create mode 100644 boinc-manager delete mode 100644 boincmanager diff --git a/boinc-LC_MESSAGES.patch b/boinc-LC_MESSAGES.patch index 763534d..643512c 100644 --- a/boinc-LC_MESSAGES.patch +++ b/boinc-LC_MESSAGES.patch @@ -1,6 +1,8 @@ ---- locale/Makefile.am 2010-04-15 13:59:36.000000000 -0500 -+++ locale/Makefile.am.orig 2010-10-04 11:03:57.000000000 -0500 -@@ -45,9 +45,9 @@ +Index: locale/Makefile.am +=================================================================== +--- locale/Makefile.am.orig ++++ locale/Makefile.am +@@ -45,9 +45,9 @@ locale_dirs = \ install-exec-hook: mydir=$(DESTDIR)$(datadir) ;\ for ldir in $(locale_dirs) ; do \ diff --git a/boinc-client-dynamic_buffers.patch b/boinc-client-dynamic_buffers.patch index 4c2753c..9ec4f7f 100644 --- a/boinc-client-dynamic_buffers.patch +++ b/boinc-client-dynamic_buffers.patch @@ -1,7 +1,7 @@ Index: lib/filesys.cpp =================================================================== ---- lib/filesys.cpp.orig 2011-05-16 18:13:03.000000000 +0200 -+++ lib/filesys.cpp 2011-05-16 18:49:23.426248908 +0200 +--- lib/filesys.cpp.orig ++++ lib/filesys.cpp @@ -36,6 +36,7 @@ #include #include diff --git a/boinc-client.changes b/boinc-client.changes index f72b684..7c476da 100644 --- a/boinc-client.changes +++ b/boinc-client.changes @@ -1,3 +1,21 @@ +------------------------------------------------------------------- +Thu Feb 2 20:32:57 UTC 2012 - chris@computersalat.de + +- rework patches +- rework sysconfig file +- rework logrotate file +- add SuSElike init script +- fix user add + * boinc needs a shell +- fix wrapper + * replace boincmanager with boinc-manager and add symlink for + backward compatibility + * fix boinc_gui -> boinc-gui +- fix License + * LGPLv3 +- fix for bnc#689499 + * a blocked boinc client, the manager works + ------------------------------------------------------------------- Fri Sep 30 20:07:45 UTC 2011 - coolo@suse.com diff --git a/boinc-client.init b/boinc-client.init new file mode 100644 index 0000000..d7bd87c --- /dev/null +++ b/boinc-client.init @@ -0,0 +1,216 @@ +#!/bin/sh +# +# Copyright (c) 2012 Scorpio IT, Deidesheim, Germany +# All rights reserved +# +# Author: Christian Wittmer +# +# /etc/init.d/boinc-client +# and its symbolic link +# /(usr/)sbin/rcboinc-client +# +### BEGIN INIT INFO +# Provides: boinc-client +# Required-Start: $syslog $network $remote_fs +# Should-Start: $time +# Required-Stop: $syslog $network $remote_fs +# Should-Stop: $time +# Default-Start: 3 5 +# Default-Stop: 0 1 2 6 +# Short-Description: BOINC daemon providing boinc-client +# Description: Start BOINC client +# For more information about BOINC (the Berkeley Open Infrastructure +# for Network Computing) see http://boinc.berkeley.edu +### END INIT INFO +# + +# Note on runlevels: +# 0 - halt/poweroff 6 - reboot +# 1 - single user 2 - multiuser without network exported +# 3 - multiuser w/ network (text mode) 5 - multiuser w/ network and X11 (xdm) +# +# Note on script names: +# http://www.linuxbase.org/spec/refspecs/LSB_1.3.0/gLSB/gLSB/scrptnames.html +# A registry has been set up to manage the init script namespace. +# http://www.lanana.org/ +# Please use the names already registered or register one or use a +# vendor prefix. + + +# Check for missing binaries (stale symlinks should not happen) +# Note: Special treatment of stop for LSB conformance +BOINC_BIN=/usr/bin/boinc-client +test -x $BOINC_BIN || { echo "$BOINC_BIN not installed"; + if [ "$1" = "stop" ]; then exit 0; + else exit 5; fi; } + +# Check for existence of needed config file and read it +BOINC_CONFIG=/etc/sysconfig/boinc-client +test -r $BOINC_CONFIG || { echo "$BOINC_CONFIG not existing"; + if [ "$1" = "stop" ]; then exit 0; + else exit 6; fi; } + +# Read config +. $BOINC_CONFIG + +# some other VARS +BOINC_SVC="BOINC Client" + +BOINC_DIR="/var/lib/boinc" +BOINCCMD_BIN="/usr/bin/boinccmd" +BOINC_LOG="/var/log/boinc-client.log" +BOINC_ERRLOG="/var/log/boinc-client.err.log" +BOINC_PIDFILE="/var/run/boinc-client.pid" +BOINC_LOCKFILE="/var/run/boinc-client.lock" + +BOINC_USR=${BOINC_BOINC_USR:="boinc"} +BOINC_GRP=${BOINC_BOINC_GRP:="boinc"} +BOINC_OPTS=${BOINC_BOINC_OPTS:=""} + +# Source LSB init functions +# providing start_daemon, killproc, pidofproc, +# log_success_msg, log_failure_msg and log_warning_msg. +# This is currently not used by UnitedLinux based distributions and +# not needed for init scripts for UnitedLinux only. If it is used, +# the functions from rc.status should not be sourced or used. +#. /lib/lsb/init-functions + +# Shell functions sourced from /etc/rc.status: +# rc_check check and set local and overall rc status +# rc_status check and set local and overall rc status +# rc_status -v be verbose in local rc status and clear it afterwards +# rc_status -v -r ditto and clear both the local and overall rc status +# rc_status -s display "skipped" and exit with status 3 +# rc_status -u display "unused" and exit with status 3 +# rc_failed set local and overall rc status to failed +# rc_failed set local and overall rc status to +# rc_reset clear both the local and overall rc status +# rc_exit exit appropriate to overall rc status +# rc_active checks whether a service is activated by symlinks +. /etc/rc.status + +# Reset status of this service +rc_reset + +# Return values acc. to LSB for all commands but status: +# 0 - success +# 1 - generic or unspecified error +# 2 - invalid or excess argument(s) +# 3 - unimplemented feature (e.g. "reload") +# 4 - user had insufficient privileges +# 5 - program is not installed +# 6 - program is not configured +# 7 - program is not running +# 8--199 - reserved (8--99 LSB, 100--149 distrib, 150--199 appl) +# +# Note that starting an already running service, stopping +# or restarting a not-running service as well as the restart +# with force-reload (in case signaling is not supported) are +# considered a success. + +case "$1" in + start) + echo -n "Starting ${BOINC_SVC} " + ## Start daemon with startproc(8). If this fails + ## the return value is set appropriately by startproc. + /sbin/startproc -u $BOINC_USR -g $BOINC_GRP -l $BOINC_LOG -s $BOINC_BIN --dir $BOINC_DIR $BOINC_OPTS + + # Remember status and be verbose + rc_status -v + ;; + stop) + echo -n "Shutting down ${BOINC_SVC} " + ## Stop daemon with killproc(8) and if this fails + ## killproc sets the return value according to LSB. + + /sbin/killproc $BOINC_BIN + + # Remember status and be verbose + rc_status -v + ;; + try-restart|condrestart) + ## Do a restart only if the service was active before. + ## Note: try-restart is now part of LSB (as of 1.9). + ## RH has a similar command named condrestart. + if test "$1" = "condrestart"; then + echo "${attn} Use try-restart ${done}(LSB)${attn} rather than condrestart ${warn}(RH)${norm}" + fi + $0 status + if test $? = 0; then + $0 restart + else + rc_reset # Not running is not a failure. + fi + # Remember status and be quiet + rc_status + ;; + restart) + ## Stop the service and regardless of whether it was + ## running or not, start it again. + $0 stop + $0 start + + # Remember status and be quiet + rc_status + ;; + force-reload) + ## Signal the daemon to reload its config. Most daemons + ## do this on signal 1 (SIGHUP). + ## If it does not support it, restart the service if it + ## is running. + + echo -n "Reload service ${BOINC_SVC} " + ## if it supports it: + #/sbin/killproc -HUP $BOINC_BIN + #touch /var/run/$BOINC_PIDFILE + + # Remember status and be verbose + #rc_status -v + + ## Otherwise: + $0 try-restart + # Remember status and be quiet + rc_status + ;; + reload) + ## Like force-reload, but if daemon does not support + ## signaling, do nothing (!) + + # If it supports signaling: + echo -n "Reload service ${BOINC_SVC} " + #/sbin/killproc -HUP $BOINC_BIN + #touch /var/run/FOO.pid + # Remember status and be verbose + #rc_status -v + + + ## Otherwise if it does not support reload: + rc_failed 3 + # Remember status and be verbose + rc_status -v + ;; + status) + echo -n "Checking for service ${BOINC_SVC} " + ## Check status with checkproc(8), if process is running + ## checkproc will return with exit status 0. + + # Return value is slightly different for the status command: + # 0 - service up and running + # 1 - service dead, but /var/run/ pid file exists + # 2 - service dead, but /var/lock/ lock file exists + # 3 - service not running (unused) + # 4 - service status unknown :-( + # 5--199 reserved (5--99 LSB, 100--149 distro, 150--199 appl.) + + # NOTE: checkproc returns LSB compliant status values. + /sbin/checkproc $BOINC_BIN + # NOTE: rc_status knows that we called this init script with + # "status" option and adapts its messages accordingly. + rc_status -v + ;; + *) + echo "Usage: $0 {start|stop|status|try-restart|restart|force-reload|reload}" + exit 1 + ;; +esac +rc_exit diff --git a/boinc-client.spec b/boinc-client.spec index 08efbdb..e7dd3d7 100644 --- a/boinc-client.spec +++ b/boinc-client.spec @@ -1,7 +1,7 @@ # # spec file for package boinc-client # -# Copyright (c) 2011 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany. # Copyright (c) 2011 by Sascha Manns # # All modifications and additions to the file contributed by third parties @@ -16,30 +16,29 @@ # Please submit bugfixes or comments via http://bugs.opensuse.org/ # -# norootforbuild # Global definitions %define _use_internal_dependency_generator 0 %define __find_requires %wx_requires %define version_ 6_10_60 %define soname 6 +%define boinc_dir %{_localstatedir}/lib/boinc Name: boinc-client Version: 6.10.60 Release: 1 Summary: The BOINC client core -License: LGPLv2+ +License: LGPLv3 Group: Productivity/Clustering/Computing Url: http://boinc.berkeley.edu/ - Source0: boinc_core_release_%{version_}.tar.bz2 Source1: boinc-icons.tar.bz2 Source2: boinc-gui.desktop Source3: README.SUSE -Source4: sysconfig.boinc-client +Source4: sysconfig.%{name} Source5: boinc-logrotate -Source6: boincmanager -Source7: boinc-client-rpmlintrc +#Source6: boincmanager +Source6: boinc-manager # The source for this package was pulled from upstream's vcs. Use the # following commands to generate the tarball: # @@ -47,6 +46,7 @@ Source7: boinc-client-rpmlintrc # # Trim all binaries and other unnecessary things. Source8: generate-tarball.sh +Source10: %{name}.init Source100: %{name}-rpmlintrc # PATCH-FIX-OPENSUSE boinc-guirpcauth.patch @@ -66,9 +66,9 @@ Patch4: boinc-docbook2x.patch # PATCH-FIX-OPENSUSE boinc-server.patch Patch5: boinc-server.patch # PATCH-FIX-OPENSUSE saigkill@opensuse.org adds define HAVE_STRCASESRTR -Patch6: boinc-client-str_util.patch +Patch6: %{name}-str_util.patch # PATCH-FIX-OPENSUSE pth@suse.de use asprintf to fix buffer overflow -Patch7: boinc-client-dynamic_buffers.patch +Patch7: %{name}-dynamic_buffers.patch # BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -114,6 +114,7 @@ Requires: cron #Requires: libboinc%{soname} = %{version}-%{release} %lang_package +%lang_package -n boinc-manager %description The Berkeley Open Infrastructure for Network Computing (BOINC) is an open- @@ -131,8 +132,7 @@ global warming, discover sources of gravitational waves, and many other types of scientific and mathematical research. %package -n boinc-manager - -Summary: GUI to control and monitor %{name} +Summary: GUI to control and monitor boinc-client Group: Productivity/Scientific/Astronomy Requires: %{name} = %{version}-%{release} Requires: boinc-manager-lang = %{version}-%{release} @@ -145,11 +145,8 @@ monitoring. The BOINC Manager has two modes of operation, the "Simple View" in which it only displays the most important information and the "Advanced View" in which all information and all control elements are available. - -%lang_package -n boinc-manager %package devel - -Summary: Development files for %{name} +Summary: Development files for boinc-client Group: Development/Libraries/C and C++ Requires: %{name} = %{version}-%{release} Requires: mysql-devel @@ -159,7 +156,6 @@ Requires: openssl-devel This package contains development files for %{name}. %package -n libboinc%{soname} - Summary: Shared Libs for %{name} Group: System/Libraries @@ -171,7 +167,6 @@ which it only displays the most important information and the "Advanced View" in which all information and all control elements are available. %package doc - Summary: Documentation files for %{name} Group: Documentation/Other %if 0%{?suse_version} >= 1120 @@ -240,50 +235,55 @@ popd %{makeinstall} # Creates default folders -%{__mkdir} -p %{buildroot}%{_datadir}/icons/hicolor/16x16/apps -%{__mkdir} -p %{buildroot}%{_datadir}/icons/hicolor/32x32/apps -%{__mkdir} -p %{buildroot}%{_datadir}/icons/hicolor/48x48/apps -%{__mkdir} -p %{buildroot}%{_initrddir} -%{__mkdir} -p %{buildroot}%{_localstatedir}/lib/boinc -%{__mkdir} -p %{buildroot}%{_mandir}/man1 -%{__mkdir} -p %{buildroot}%{_sysconfdir}/logrotate.d/ +%{__install} -dm0755 %{buildroot}%{boinc_dir} +%{__install} -dm0755 %{buildroot}%{_mandir}/man1 # Remove old boinc & rename boinc_client to boinc-client -%{__rm} -f %{buildroot}%{_bindir}/boinc -%{__mv} -f %{buildroot}%{_bindir}/boinc_client %{buildroot}%{_bindir}/boinc-client +%{__rm} -f %{buildroot}%{_bindir}/boinc +%{__mv} -f %{buildroot}%{_bindir}/boinc_client %{buildroot}%{_bindir}/%{name} + +# Rename boincmgr and wrap it +%{__mv} %{buildroot}%{_bindir}/boincmgr %{buildroot}%{_bindir}/boinc-gui + +# Install boinc-manager wrapper script +%{__install} -Dm0755 %{S:6} %{buildroot}%{_bindir}/boinc-manager # Use symlink instead of hardlink pushd %{buildroot}%{_bindir} -/bin/ln -sf boinc-client boinc -popd +%{__ln_s} -f %{name} boinc +%{__ln_s} -f boinc-manager boincmgr +popd -# Rename boincmgr and wrap it -%{__mv} %{buildroot}%{_bindir}/boincmgr %{buildroot}%{_bindir}/boinc_gui - -# Install boincmanager wrapper script -%{__install} -Dm0755 %{S:6} %{buildroot}%{_bindir}/boincmanager +# replace @boinc_dir@, @bindir@ +%{__sed} -i \ + -e "s,@boincdir@,%{boinc_dir},g" \ + -e "s,@bindir@,%{_bindir},g" \ + %{buildroot}%{_bindir}/boinc-manager # Remove /etc/sysconfig/boinc-client, it is added by %%fillup_and_insserv -%{__rm} -f %{buildroot}%{_sysconfdir}/sysconfig/boinc-client +%{__rm} -f %{buildroot}%{_sysconfdir}/sysconfig/%{name} -# Install logrotate and create symlink to /etc/init.d/boinc-client -%{__install} -dm0755 %{buildroot}%{_sbindir} -/bin/ln -sf %{_sysconfdir}/init.d/boinc-client %{buildroot}%{_sbindir}/rcboinc-client +# Install init and create symlink to /etc/init.d/boinc-client +%{__install} -Dm0755 %{S:10} %{buildroot}%{_initrddir}/%{name} +%{__install} -dm0755 %{buildroot}%{_sbindir} +/bin/ln -sf %{_sysconfdir}/init.d/%{name} %{buildroot}%{_sbindir}/rc%{name} + +# Install logrotate %{__install} -Dm0644 %{S:5} %{buildroot}%{_sysconfdir}/logrotate.d/%{name} # Install bash completition %{__install} -Dpm0644 client/scripts/boinc.bash %{buildroot}%{_sysconfdir}/bash_completion.d/boinc -# Install template for sysconfig -%{__install} -Dm0644 %{S:4} %{buildroot}/var/adm/fillup-templates/sysconfig.boinc-client +# Install template for sysconfig +%{__install} -Dm0644 %{S:4} %{buildroot}/var/adm/fillup-templates/sysconfig.%{name} # Install desktop-file and icons -%{__install} -Dm0644 boinc-gui-128.png %{buildroot}%{_datadir}/icons/hicolor/128x128/apps/boinc-gui.png -%{__install} -Dm0644 boinc-gui-64.png %{buildroot}%{_datadir}/icons/hicolor/64x64/apps/boinc-gui.png -%{__install} -Dm0644 boinc-gui-48.png %{buildroot}%{_datadir}/icons/hicolor/48x48/apps/boinc-gui.png -%{__install} -Dm0644 boinc-gui-32.png %{buildroot}%{_datadir}/icons/hicolor/32x32/apps/boinc-gui.png -%{__install} -Dm0644 boinc-gui-22.png %{buildroot}%{_datadir}/icons/hicolor/22x22/apps/boinc-gui.png -%{__install} -Dm0644 boinc-gui-16.png %{buildroot}%{_datadir}/icons/hicolor/16x16/apps/boinc-gui.png +%{__install} -Dm0644 boinc-gui-128.png %{buildroot}%{_datadir}/icons/hicolor/128x128/apps/boinc-gui.png +%{__install} -Dm0644 boinc-gui-64.png %{buildroot}%{_datadir}/icons/hicolor/64x64/apps/boinc-gui.png +%{__install} -Dm0644 boinc-gui-48.png %{buildroot}%{_datadir}/icons/hicolor/48x48/apps/boinc-gui.png +%{__install} -Dm0644 boinc-gui-32.png %{buildroot}%{_datadir}/icons/hicolor/32x32/apps/boinc-gui.png +%{__install} -Dm0644 boinc-gui-22.png %{buildroot}%{_datadir}/icons/hicolor/22x22/apps/boinc-gui.png +%{__install} -Dm0644 boinc-gui-16.png %{buildroot}%{_datadir}/icons/hicolor/16x16/apps/boinc-gui.png # Move and rename icons %{__mv} %{buildroot}%{_datadir}/boinc/boincmgr.16x16.png %{buildroot}%{_datadir}/icons/hicolor/16x16/apps/boincmgr.png @@ -299,7 +299,7 @@ popd # Relinking Manpages /bin/ln -sf boincmgr.1.gz %{buildroot}%{_mandir}/man1/boincmanager.1.gz /bin/ln -sf boinccmd.1.gz %{buildroot}%{_mandir}/man1/boinccmd.1.gz -/bin/ln -sf boinc.1.gz %{buildroot}%{_mandir}/man1/boinc.1.gz +/bin/ln -sf boinc.1.gz %{buildroot}%{_mandir}/man1/boinc.1.gz # Fix spurious-executable-perm %{__chmod} 0644 doc/*.php @@ -316,21 +316,21 @@ popd %{__rm} -rf '%{buildroot}' %pre -# Add boinc user and group -getent group boinc >/dev/null || groupadd -r boinc -getent passwd boinc >/dev/null || \ -useradd -r -g boinc -d %{_localstatedir}/lib/boinc -s /sbin/nologin \ - -c "BOINC client account." boinc -exit 0 - -%post -%fillup_and_insserv boinc-client +# add group +%{_sbindir}/groupadd -r boinc 2>/dev/null || : +# add user +%{_sbindir}/useradd -c "BOINC Client" -d "%{_localstatedir}/lib/boinc" \ + -g boinc -r -s /bin/bash boinc 2>/dev/null || : %preun -%stop_on_removal boinc-client +%stop_on_removal %{name} -%postun -%restart_on_update boinc-client +%post +%fillup_and_insserv %{name} +%{_sbindir}/usermod -c "BOINC Client" boinc 2>/dev/null || : + +%postun +%restart_on_update %{name} %insserv_cleanup %post -n boinc-manager @@ -355,13 +355,13 @@ fi %files %defattr(-,root,root,-) -%doc COPYING COPYRIGHT INSTALL notes todo TODO_OLD README.SUSE +%doc COPYING* COPYRIGHT INSTALL notes todo TODO_OLD README.SUSE %config(noreplace) %{_sysconfdir}/logrotate.d/%{name} %config(noreplace) %{_sysconfdir}/bash_completion.d/ -/var/adm/fillup-templates/sysconfig.boinc-client +/var/adm/fillup-templates/sysconfig.%{name} %{_bindir}/boinc -%{_bindir}/boinc-client -%{_sbindir}/rcboinc-client +%{_bindir}/%{name} +%{_sbindir}/rc%{name} %{_bindir}/boinccmd %{_bindir}/switcher %{_initrddir}/%{name} @@ -373,12 +373,13 @@ fi %files doc %defattr(-,root,root,-) %doc checkin_* -%doc doc/*.txt doc/bolt doc/logo doc/*.php doc/*.png doc/*.html +%doc doc/*.txt doc/bolt doc/logo doc/*.php doc/*.png doc/*.html %files -n boinc-manager %defattr(-,root,root,-) -%{_bindir}/boinc_gui -%{_bindir}/boincmanager +%{_bindir}/boinc-gui +%{_bindir}/boinc-manager +%{_bindir}/boincmgr %{_datadir}/applications/boinc-gui.desktop %{_datadir}/icons/hicolor/*/apps/* %{_mandir}/man1/boincmgr.1.gz diff --git a/boinc-completion.patch b/boinc-completion.patch index da4f02b..0f88e89 100644 --- a/boinc-completion.patch +++ b/boinc-completion.patch @@ -1,6 +1,8 @@ ---- client/scripts/boinc.bash 2008-05-16 10:01:52.000000000 -0500 -+++ client/scripts/boinc.bash.orig 2010-10-04 11:19:36.000000000 -0500 -@@ -36,7 +36,7 @@ +Index: client/scripts/boinc.bash +=================================================================== +--- client/scripts/boinc.bash.orig ++++ client/scripts/boinc.bash +@@ -36,7 +36,7 @@ _boinc() return 0 fi } diff --git a/boinc-docbook2x.patch b/boinc-docbook2x.patch index 5238936..a77022e 100644 --- a/boinc-docbook2x.patch +++ b/boinc-docbook2x.patch @@ -1,6 +1,8 @@ ---- configure.ac 2010-07-01 12:09:41.000000000 -0500 -+++ configure.ac.orig 2010-10-03 16:24:03.000000000 -0500 -@@ -284,7 +284,7 @@ +Index: configure.ac +=================================================================== +--- configure.ac.orig ++++ configure.ac +@@ -284,7 +284,7 @@ AC_SUBST([TOP_BUILD_DIR], [`pwd`]) dnl Check for docbook2x-man, which we use to create the manpages in dnl doc/manpages, and set the conditional HAVE_DOCBOOK2X_MAN to build dnl the manpages only if docbook2x-man is available. diff --git a/boinc-guirpcauth.patch b/boinc-guirpcauth.patch index 2755fff..5fb727c 100644 --- a/boinc-guirpcauth.patch +++ b/boinc-guirpcauth.patch @@ -1,6 +1,8 @@ ---- client/gui_rpc_server.cpp 2010-06-18 11:45:45.000000000 -0500 -+++ client/gui_rpc_server.cpp.orig 2010-10-04 13:23:39.000000000 -0500 -@@ -146,12 +146,7 @@ +Index: client/gui_rpc_server.cpp +=================================================================== +--- client/gui_rpc_server.cpp.orig ++++ client/gui_rpc_server.cpp +@@ -146,12 +146,7 @@ int GUI_RPC_CONN_SET::get_password() { // they can cause code to execute as this user. // So better protect it. // diff --git a/boinc-init.patch b/boinc-init.patch index 79d042d..059337c 100644 --- a/boinc-init.patch +++ b/boinc-init.patch @@ -2,7 +2,7 @@ Index: client/scripts/boinc-client.in =================================================================== --- client/scripts/boinc-client.in.orig +++ client/scripts/boinc-client.in -@@ -19,13 +19,13 @@ +@@ -19,14 +19,16 @@ # For more information about BOINC (the Berkeley Open Infrastructure # for Network Computing) see http://boinc.berkeley.edu # processname: boinc @@ -10,17 +10,22 @@ Index: client/scripts/boinc-client.in +# config: /etc/sysconfig/boinc-client # ### BEGIN INIT INFO - # Provides: boinc +-# Provides: boinc -# Required-Start: $network -# Required-Stop: $network -# Default-Start: 3 4 5 -+# Required-Start: $network $remote_fs -+# Required-Stop: $network $remote_fs -+# Default-Start: 3 5 - # Default-Stop: 0 1 2 6 +-# Default-Stop: 0 1 2 6 ++# Provides: boinc-client ++# Required-Start: $network $remote_fs ++# Should-Start: $time ++# Required-Stop: $network $remote_fs ++# Should-Stop: $time ++# Default-Start: 3 5 ++# Default-Stop: 0 1 2 6 # Short-Description: This script monitors the BOINC client. # Description: This script starts the local BOINC client as a daemon -@@ -117,6 +117,10 @@ fi + # For more information about BOINC (the Berkeley Open Infrastructure +@@ -117,6 +119,10 @@ fi # BOINCUSER=boinc @@ -31,7 +36,7 @@ Index: client/scripts/boinc-client.in # Working directory. Could be /home/boinc, /var/lib/boinc, etc.. # The reason I prefer /var/lib/boinc is that this works best for a # cluster of computers where /home/anything might be shared between machines -@@ -128,7 +132,7 @@ BOINCDIR=/var/lib/boinc +@@ -128,7 +134,7 @@ BOINCDIR=/var/lib/boinc # but I like to rename it and put it in a public place. # (Hint: move boincmgr to /usr/local/bin too so anyone can easily use it). # @@ -40,7 +45,7 @@ Index: client/scripts/boinc-client.in BOINCEXE=${bindir}/${BOINCEXE_NAME} BOINCCMD_NAME=boinccmd BOINCCMD=${bindir}/${BOINCCMD_NAME} -@@ -161,9 +165,7 @@ BOINCOPTS= +@@ -161,9 +167,7 @@ BOINCOPTS= # Subsys lock file ... # If there is the subsys directory, then use it ... @@ -51,7 +56,7 @@ Index: client/scripts/boinc-client.in LOCKFILE=/var/lock/${BOINCEXE_NAME} elif [ -d /var/run ]; then LOCKFILE=/var/run/${BOINCEXE_NAME}.lock -@@ -178,8 +180,8 @@ export TERM=dumb +@@ -178,8 +182,8 @@ export TERM=dumb # but if the functions are not found we create our own simple replacements. # (The idea for replacing the functions comes from OpenAFS. Thanks guys!) @@ -62,7 +67,7 @@ Index: client/scripts/boinc-client.in else if printf "Hello" >/dev/null 2>/dev/null ; then # printf works -@@ -279,7 +281,7 @@ if [ ! -d $BOINCDIR ]; then +@@ -279,7 +283,7 @@ if [ ! -d $BOINCDIR ]; then echo -n "Creating $BOINCDIR " if mkdir -p $BOINCDIR 2>/dev/null ; then if [ -n "$BOINCUSER" ] ; then @@ -71,7 +76,7 @@ Index: client/scripts/boinc-client.in echo_success else echo_failure -@@ -329,8 +331,8 @@ if [ "${USERNOW}" = "${BOINCUSER}" ] ; t +@@ -329,8 +333,8 @@ if [ "${USERNOW}" = "${BOINCUSER}" ] ; t exit 8 fi elif [ "${USERNOW}" = "root" ] ; then diff --git a/boinc-logrotate b/boinc-logrotate index 078e57c..ca8986c 100644 --- a/boinc-logrotate +++ b/boinc-logrotate @@ -1,27 +1,27 @@ /var/log/boinc-client.log { - daily - compress - dateext - notifempty - rotate 99 - size 4M - missingok - create 640 root root - postrotate - /etc/init.d/boinc-client restart - endscript + daily + compress + dateext + notifempty + rotate 99 + size +4096k + missingok + create 644 root root + postrotate + /etc/init.d/boinc-client restart > /dev/null + endscript } -/var/log/boinc-client_err.log { - daily - compress - dateext - notifempty - rotate 99 - size 4M - missingok - create 640 root root - postrotate - /etc/init.d/boinc-client restart - endscript -} +#/var/log/boinc-client_err.log { +# daily +# compress +# dateext +# notifempty +# rotate 99 +# size +4096k +# missingok +# create 644 root root +# postrotate +# /etc/init.d/boinc-client restart > /dev/null +# endscript +#} diff --git a/boinc-manager b/boinc-manager new file mode 100644 index 0000000..8f72960 --- /dev/null +++ b/boinc-manager @@ -0,0 +1,10 @@ +#!/bin/sh +# +# boinc-manager - a wrapper to start BOINC Client GUI +# +# Checking for gui_rpc_auth.cfg +if ! test -f ~/gui_rpc_auth.cfg ; then + ln -s @boinc_dir@/gui_rpc_auth.cfg ~/. +fi + +exec boinc-gui -e @bindir@ diff --git a/boinc-server.patch b/boinc-server.patch index 3184bfb..4fd971c 100644 --- a/boinc-server.patch +++ b/boinc-server.patch @@ -1,6 +1,8 @@ ---- sched/handle_request.cpp 2010-01-14 15:18:06.000000000 -0600 -+++ sched/handle_request.cpp.orig 2010-10-04 11:24:03.000000000 -0500 -@@ -143,7 +143,9 @@ +Index: sched/handle_request.cpp +=================================================================== +--- sched/handle_request.cpp.orig ++++ sched/handle_request.cpp +@@ -143,7 +143,9 @@ int lock_sched() { // write PID into the CGI_ file and flush to disk // count = sprintf(pid_string, "%d\n", getpid()); diff --git a/boincmanager b/boincmanager deleted file mode 100644 index ccd03c0..0000000 --- a/boincmanager +++ /dev/null @@ -1,32 +0,0 @@ -#!/bin/sh -# -# BOINC Manager on Unix -#!/bin/sh -# -# BOINC - start the BOINC Manager - -# Source the configuration file for the boinc-client init script. -# -config_files="/etc/boinc-client.conf /etc/sysconfig/boinc-client" - -# provide a default -BOINCDIR=/var/lib/boinc - -# Find the correct config file -# -for config_file in $config_files ; do - if [ -f ${config_file} ] ; then - . ${config_file}; - break; - fi -done - -# Checking for gui_rpc_auth.cfg -if ! test -f ~/gui_rpc_auth.cfg ; then - ln -s /var/lib/boinc/gui_rpc_auth.cfg . -fi - -# Change directory and start BOINC Manager -# -cd "$BOINCDIR" -exec boinc-gui diff --git a/sysconfig.boinc-client b/sysconfig.boinc-client index 6a5226e..8e84969 100644 --- a/sysconfig.boinc-client +++ b/sysconfig.boinc-client @@ -1,43 +1,42 @@ -# -*- mode:sh; mode:font-lock; -*- -# Default variable values for the boinc-client /etc/init.d script + +## Path: Productivity/Clustering/Computing +## Description: define BOINC user +## Type: string +## Default: "boinc" +## Config: BOINC # -BOINCEXE_NAME=boinc-client -BOINCCMD_NAME=boinccmd - -# The userid under which boinc-client is run -BOINCUSER=boinc -BOINCGROUP=boinc - -# The directory in which boinc-client is run -BOINCDIR=/var/lib/boinc - -# log files -LOGFILE=/var/log/${BOINCEXE_NAME}.log -ERRORLOG=/var/log/${BOINCEXE_NAME}_err.log - -# pid file -PIDFILE=/var/run/${BOINCEXE_NAME}.pid - -# placement of the lockfile depends upon the operating system -# it will probably be one of the following: -#LOCKFILE=/var/lock/${BOINCEXE_NAME} -#LOCKFILE=/var/run/${BOINCEXE_NAME}.lock -#LOCKFILE=/var/lock/subsys/${BOINCEXE_NAME} -LOCKFILE=/var/run/${BOINCEXE_NAME}.lock - -# BOINC options: for the command line when running the client. -# Be aware that --allow_remote_gui_rpc opens up your machine to the world! +# An empty setting will point to boinc # -# The default is no options. -BOINCOPTS= -# Add this option if you want to allow boinc manager connections from remote -# machines -#BOINCOPTS="--allow_remote_gui_rpc" -# Add this option if you want to turn off all logging -#BOINCOPTS="--daemon" -# Add this option if you want to redirect logging to the files stderrdae.txt -# and stdoutdae.txt in BOINCDIR rather than LOGFILE and ERRORLOG -#BOINCOPTS="--redirectio" -# Add this option if you want to run only when no logins from anywhere are -# active -#BOINCOPTS="--check_all_logins" +BOINC_BOINC_USR="boinc" + +## Path: Productivity/Clustering/Computing +## Description: define BOINC group +## Type: string +## Default: "boinc" +## Config: BOINC +# +# An empty setting will point to boinc +# +BOINC_BOINC_GRP="boinc" + +## Path: Productivity/Clustering/Computing +## Description: define BOINC options +## Type: string +## Default: "" +## Config: BOINC +# +## --allow_remote_gui_rpc +## allow boinc manager connections from remote machines +## +## --daemon +## turn off all logging +## +## --redirectio +## redirect logging to the files stderrdae.txt and stdoutdae.txt +## in BOINCDIR rather than LOGFILE and ERRORLOG +## +## --check_all_logins +## run only when no logins from anywhere are active +## +# +BOINC_BOINC_OPTS="" From ed6947f31971ccb26d2677a9590106e07832ef9166a43bc27fe11fcb4545156d Mon Sep 17 00:00:00 2001 From: Christian Wittmer Date: Sat, 4 Feb 2012 00:38:54 +0000 Subject: [PATCH 2/7] fix boinc-client deps OBS-URL: https://build.opensuse.org/package/show/network/boinc-client?expand=0&rev=18 --- boinc-client.changes | 6 ++++++ boinc-client.spec | 3 ++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/boinc-client.changes b/boinc-client.changes index 7c476da..d15a74c 100644 --- a/boinc-client.changes +++ b/boinc-client.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Sat Feb 4 00:37:37 UTC 2012 - chris@computersalat.de + +- fix deps for boinc-client + * Requires libboinc6 + ------------------------------------------------------------------- Thu Feb 2 20:32:57 UTC 2012 - chris@computersalat.de diff --git a/boinc-client.spec b/boinc-client.spec index e7dd3d7..2c5a2b4 100644 --- a/boinc-client.spec +++ b/boinc-client.spec @@ -111,7 +111,8 @@ BuildRequires: wxWidgets-devel >= 2.8.7 Requires: logrotate Requires: cron -#Requires: libboinc%{soname} = %{version}-%{release} +## !! Do not remove thie "hard" dependency !! +Requires: libboinc%{soname} = %{version}-%{release} %lang_package %lang_package -n boinc-manager From 2e1857bb8acc2dd841e8b5eac4185ab4a79391bdab6e28d9ab3ca090587691c2 Mon Sep 17 00:00:00 2001 From: Christian Wittmer Date: Sun, 5 Feb 2012 23:23:12 +0000 Subject: [PATCH 3/7] Accepting request 102826 from home:computersalat:branches:network manager subpkg as standalone possible, fix desktop file OBS-URL: https://build.opensuse.org/request/show/102826 OBS-URL: https://build.opensuse.org/package/show/network/boinc-client?expand=0&rev=19 --- boinc-client.changes | 7 +++++++ boinc-client.spec | 4 +++- boinc-gui.desktop | 2 +- 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/boinc-client.changes b/boinc-client.changes index d15a74c..76261ec 100644 --- a/boinc-client.changes +++ b/boinc-client.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Sun Feb 5 23:11:38 UTC 2012 - chris@computersalat.de + +- remove client dep of manager + * manager does not really need a local boinc-client ;) +- fix desktop file + ------------------------------------------------------------------- Sat Feb 4 00:37:37 UTC 2012 - chris@computersalat.de diff --git a/boinc-client.spec b/boinc-client.spec index 2c5a2b4..9c59b5b 100644 --- a/boinc-client.spec +++ b/boinc-client.spec @@ -135,7 +135,7 @@ of scientific and mathematical research. %package -n boinc-manager Summary: GUI to control and monitor boinc-client Group: Productivity/Scientific/Astronomy -Requires: %{name} = %{version}-%{release} +#Requires: %{name} = %{version}-%{release} Requires: boinc-manager-lang = %{version}-%{release} Requires: hicolor-icon-theme @@ -253,6 +253,7 @@ popd pushd %{buildroot}%{_bindir} %{__ln_s} -f %{name} boinc %{__ln_s} -f boinc-manager boincmgr +%{__ln_s} -f boinc-manager boincmanager popd # replace @boinc_dir@, @bindir@ @@ -381,6 +382,7 @@ fi %{_bindir}/boinc-gui %{_bindir}/boinc-manager %{_bindir}/boincmgr +%{_bindir}/boincmanager %{_datadir}/applications/boinc-gui.desktop %{_datadir}/icons/hicolor/*/apps/* %{_mandir}/man1/boincmgr.1.gz diff --git a/boinc-gui.desktop b/boinc-gui.desktop index aa87f69..b111983 100644 --- a/boinc-gui.desktop +++ b/boinc-gui.desktop @@ -1,6 +1,6 @@ [Desktop Entry] Encoding=UTF-8 -Exec=boincmanager +Exec=boinc-manager Icon=boinc-gui Terminal=false Type=Application From 5f412f9688b7e428e84cf62bdb9ad47d3ec5da569fc4c5a6770cb6aec18574ce Mon Sep 17 00:00:00 2001 From: Christian Wittmer Date: Mon, 6 Feb 2012 15:06:42 +0000 Subject: [PATCH 4/7] fix License to LGPL-3.0 OBS-URL: https://build.opensuse.org/package/show/network/boinc-client?expand=0&rev=20 --- boinc-client.changes | 6 ++++++ boinc-client.spec | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/boinc-client.changes b/boinc-client.changes index 76261ec..275ca4e 100644 --- a/boinc-client.changes +++ b/boinc-client.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Mon Feb 6 15:05:05 UTC 2012 - chris@computersalat.de + +- fix License (http://www.spdx.org/licenses/) + * LGPL-3.0 + ------------------------------------------------------------------- Sun Feb 5 23:11:38 UTC 2012 - chris@computersalat.de diff --git a/boinc-client.spec b/boinc-client.spec index 9c59b5b..fc362f5 100644 --- a/boinc-client.spec +++ b/boinc-client.spec @@ -28,7 +28,7 @@ Name: boinc-client Version: 6.10.60 Release: 1 Summary: The BOINC client core -License: LGPLv3 +License: LGPL-3.0 Group: Productivity/Clustering/Computing Url: http://boinc.berkeley.edu/ Source0: boinc_core_release_%{version_}.tar.bz2 From fb30f4ad97335fab22acc0905c4e185be7e61f80894efa4124388b83756a4bf9 Mon Sep 17 00:00:00 2001 From: Christian Wittmer Date: Wed, 8 Feb 2012 23:10:31 +0000 Subject: [PATCH 5/7] Accepting request 103459 from home:computersalat:branches:network fix replacing old sysconfig file OBS-URL: https://build.opensuse.org/request/show/103459 OBS-URL: https://build.opensuse.org/package/show/network/boinc-client?expand=0&rev=21 --- boinc-client.changes | 5 +++++ boinc-client.spec | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/boinc-client.changes b/boinc-client.changes index 275ca4e..9cfb783 100644 --- a/boinc-client.changes +++ b/boinc-client.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Wed Feb 8 22:39:34 UTC 2012 - chris@computersalat.de + +- fix replacing old sysconfig file + ------------------------------------------------------------------- Mon Feb 6 15:05:05 UTC 2012 - chris@computersalat.de diff --git a/boinc-client.spec b/boinc-client.spec index fc362f5..23f67d1 100644 --- a/boinc-client.spec +++ b/boinc-client.spec @@ -323,6 +323,11 @@ popd # add user %{_sbindir}/useradd -c "BOINC Client" -d "%{_localstatedir}/lib/boinc" \ -g boinc -r -s /bin/bash boinc 2>/dev/null || : +if [ -f %{_sysconfdir}/sysconfig/%{name} ]; then + if [ "$(grep "BOINC_BOINC_USR" /etc/sysconfig/boinc-client | grep -v grep >/dev/null; echo $?)" == 1 ]; then + mv -f %{_sysconfdir}/sysconfig/%{name} %{_sysconfdir}/sysconfig/%{name}.save + fi +fi %preun %stop_on_removal %{name} From 06e611d27cc8707dfddc03e55988c413ad7deed274af894d9bfee125a9ee0059 Mon Sep 17 00:00:00 2001 From: Christian Wittmer Date: Wed, 8 Feb 2012 23:44:31 +0000 Subject: [PATCH 6/7] Accepting request 103461 from home:computersalat:branches:network fix changelog OBS-URL: https://build.opensuse.org/request/show/103461 OBS-URL: https://build.opensuse.org/package/show/network/boinc-client?expand=0&rev=22 --- boinc-client.changes | 1 + boinc-client.spec | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/boinc-client.changes b/boinc-client.changes index 9cfb783..2e97bca 100644 --- a/boinc-client.changes +++ b/boinc-client.changes @@ -2,6 +2,7 @@ Wed Feb 8 22:39:34 UTC 2012 - chris@computersalat.de - fix replacing old sysconfig file +- revert boinc users shell to /sbin/nologin ------------------------------------------------------------------- Mon Feb 6 15:05:05 UTC 2012 - chris@computersalat.de diff --git a/boinc-client.spec b/boinc-client.spec index 23f67d1..65e7535 100644 --- a/boinc-client.spec +++ b/boinc-client.spec @@ -322,7 +322,7 @@ popd %{_sbindir}/groupadd -r boinc 2>/dev/null || : # add user %{_sbindir}/useradd -c "BOINC Client" -d "%{_localstatedir}/lib/boinc" \ - -g boinc -r -s /bin/bash boinc 2>/dev/null || : + -g boinc -r -s /sbin/nologin boinc 2>/dev/null || : if [ -f %{_sysconfdir}/sysconfig/%{name} ]; then if [ "$(grep "BOINC_BOINC_USR" /etc/sysconfig/boinc-client | grep -v grep >/dev/null; echo $?)" == 1 ]; then mv -f %{_sysconfdir}/sysconfig/%{name} %{_sysconfdir}/sysconfig/%{name}.save From 74b63951d20b800d341793e60ee3c91078dac841e7d441f6558e6a70ac42a245 Mon Sep 17 00:00:00 2001 From: Christian Wittmer Date: Fri, 10 Feb 2012 23:18:48 +0000 Subject: [PATCH 7/7] Accepting request 103766 from home:computersalat:branches:network fix for bnc#732118, bnc#744389, bnc#744612, bnc#745887 OBS-URL: https://build.opensuse.org/request/show/103766 OBS-URL: https://build.opensuse.org/package/show/network/boinc-client?expand=0&rev=23 --- boinc-client.changes | 13 +++++++++++++ boinc-client.spec | 16 +++++++++++----- 2 files changed, 24 insertions(+), 5 deletions(-) diff --git a/boinc-client.changes b/boinc-client.changes index 2e97bca..328b595 100644 --- a/boinc-client.changes +++ b/boinc-client.changes @@ -1,3 +1,16 @@ +------------------------------------------------------------------- +Fri Feb 10 23:07:01 UTC 2012 - chris@computersalat.de + +- fix sed for boinc-manager + +------------------------------------------------------------------- +Wed Feb 8 22:51:55 UTC 2012 - chris@computersalat.de + +- fix for bnc#745887 ( Confirm licensing of boinc-client 6.10.60 ) +- fix for bnc#744612 ( File /usr/bin/boinc_gui incorrectly named ) +- fix for bnc#744389 ( boinc-client will not run ) +- fix for bnc#732118 ( BOINC installs but will not run ) + ------------------------------------------------------------------- Wed Feb 8 22:39:34 UTC 2012 - chris@computersalat.de diff --git a/boinc-client.spec b/boinc-client.spec index 65e7535..b53564e 100644 --- a/boinc-client.spec +++ b/boinc-client.spec @@ -19,7 +19,9 @@ # Global definitions %define _use_internal_dependency_generator 0 +%if 0%{?suse_version} >= 1140 %define __find_requires %wx_requires +%endif %define version_ 6_10_60 %define soname 6 %define boinc_dir %{_localstatedir}/lib/boinc @@ -37,7 +39,6 @@ Source2: boinc-gui.desktop Source3: README.SUSE Source4: sysconfig.%{name} Source5: boinc-logrotate -#Source6: boincmanager Source6: boinc-manager # The source for this package was pulled from upstream's vcs. Use the # following commands to generate the tarball: @@ -111,8 +112,6 @@ BuildRequires: wxWidgets-devel >= 2.8.7 Requires: logrotate Requires: cron -## !! Do not remove thie "hard" dependency !! -Requires: libboinc%{soname} = %{version}-%{release} %lang_package %lang_package -n boinc-manager @@ -135,7 +134,6 @@ of scientific and mathematical research. %package -n boinc-manager Summary: GUI to control and monitor boinc-client Group: Productivity/Scientific/Astronomy -#Requires: %{name} = %{version}-%{release} Requires: boinc-manager-lang = %{version}-%{release} Requires: hicolor-icon-theme @@ -206,6 +204,14 @@ pushd clientgui/res/skins/default/graphic/ %{__sed} -i 's/static char/static const char/g' *.xpm popd +### bnc#745656 +## remove files with questionable licenses +# removing NVIDIA owned file that does not clearly allow redistribution or +# modification +%{__rm} coprocs/CUDA/include/nvapi.h +# removing unnecessary APSL licensed files +%{__rm} client/app_stats_mac.cpp + %build #remove ltmain.sh & run libtoolize and ./_autosetup %{__rm} ltmain.sh @@ -258,7 +264,7 @@ popd # replace @boinc_dir@, @bindir@ %{__sed} -i \ - -e "s,@boincdir@,%{boinc_dir},g" \ + -e "s,@boinc_dir@,%{boinc_dir},g" \ -e "s,@bindir@,%{_bindir},g" \ %{buildroot}%{_bindir}/boinc-manager