1
0
forked from pool/boinc-client

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
This commit is contained in:
Christian Wittmer 2012-02-08 23:10:31 +00:00 committed by Git OBS Bridge
parent 5f412f9688
commit fb30f4ad97
2 changed files with 10 additions and 0 deletions

View File

@ -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

View File

@ -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}