mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-25 17:51:01 +00:00
Fixed, tidied, tested
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@8935 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
5ba6b17202
commit
6f07550ada
1 changed files with 36 additions and 27 deletions
|
@ -1,35 +1,44 @@
|
||||||
%post
|
%post
|
||||||
if [ -z "$GNUSTEP_SYSTEM_ROOT" ]; then
|
if [ $1 = 1 ]; then
|
||||||
. %{gsr}/Makefiles/GNUstep.sh
|
# if [ -z "$GNUSTEP_SYSTEM_ROOT" ]; then
|
||||||
fi
|
# . %{gs_root}/Makefiles/GNUstep.sh
|
||||||
grep -q '^gdomap' /etc/services || (echo "gdomap 538/tcp # GNUstep distrib objects" >> /etc/services && echo "gdomap 538/udp # GNUstep distrib objects" >> /etc/services)
|
# fi
|
||||||
%ifos Linux
|
|
||||||
grep -q '%{gsr}/Libraries/$GNUSTEP_HOST_CPU/$GNUSTEP_HOST_OS/gnu-gnu-gnu-xgps' /etc/ld.so.conf || echo "%{gsr}/Libraries/$GNUSTEP_HOST_CPU/$GNUSTEP_HOST_OS/%{libcombo}" >> /etc/ld.so.conf
|
#==============================================================
|
||||||
/sbin/ldconfig
|
# Add lines for gdomap into /etc/services, if not already there
|
||||||
/sbin/chkconfig --add gnustep
|
#==============================================================
|
||||||
%endif
|
grep -q '^gdomap' /etc/services \
|
||||||
|
|| (echo "gdomap 538/tcp # GNUstep distributed objects" >> /etc/services \
|
||||||
|
&& echo "gdomap 538/udp # GNUstep distributed objects" >> /etc/services)
|
||||||
|
|
||||||
|
#
|
||||||
|
# Need to add paths to ld.so.conf in gnustep-make if we want to do this
|
||||||
|
#
|
||||||
|
#%ifos Linux
|
||||||
|
#/sbin/ldconfig
|
||||||
|
#%endif
|
||||||
|
|
||||||
%preun
|
|
||||||
if [ -z "$GNUSTEP_SYSTEM_ROOT" ]; then
|
|
||||||
. %{gsr}/Makefiles/GNUstep.sh
|
|
||||||
fi
|
|
||||||
if [ $1 = 0 ]; then
|
|
||||||
/sbin/chkconfig --del gnustep
|
|
||||||
mv -f /etc/services /etc/services.orig
|
|
||||||
grep -v "^gdomap 538" /etc/services.orig > /etc/services
|
|
||||||
rm -f /etc/services.orig
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
%postun
|
%postun
|
||||||
if [ -z "$GNUSTEP_SYSTEM_ROOT" ]; then
|
|
||||||
. %{gsr}/Makefiles/GNUstep.sh
|
|
||||||
fi
|
|
||||||
if [ $1 = 0 ]; then
|
if [ $1 = 0 ]; then
|
||||||
%ifos Linux
|
# if [ -z "$GNUSTEP_SYSTEM_ROOT" ]; then
|
||||||
mv -f /etc/ld.so.conf /etc/ld.so.conf.orig
|
# . %{gs_root}/Makefiles/GNUstep.sh
|
||||||
grep -v "^%{gsr}/Libraries/$GNUSTEP_HOST_CPU/$GNUSTEP_HOST_OS/%{libcombo}$" /etc/ld.so.conf.orig > /etc/ld.so.conf
|
# fi
|
||||||
rm -f /etc/ld.so.conf.orig
|
|
||||||
/sbin/ldconfig
|
#=========================================
|
||||||
%endif
|
# Remove lines for gdomap in /etc/services
|
||||||
|
#=========================================
|
||||||
|
mv -f /etc/services /etc/services.orig
|
||||||
|
grep -v "^gdomap 538" /etc/services.orig > /etc/services
|
||||||
|
rm -f /etc/services.orig
|
||||||
|
|
||||||
|
#
|
||||||
|
# Need to add paths to ld.so.conf in gnustep-make if we want to do this
|
||||||
|
#
|
||||||
|
#%ifos Linux
|
||||||
|
#/sbin/ldconfig
|
||||||
|
#%endif
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in a new issue