diff options
author | Menno Duursma <druiloor@zonnet.nl> | 2010-10-19 17:11:22 +0100 |
---|---|---|
committer | Michiel van Wessem <michiel@slackbuilds.org> | 2010-10-19 17:11:22 +0100 |
commit | 1f03a0e8f069db34508633d2df61701eba96368e (patch) | |
tree | bb0b9e0f759747367f199e87a92c7190873eb9e7 /network/heimdal/doinst.sh | |
parent | 584ec3e1a28c6c302ddb506e388e5424b0835fee (diff) | |
download | slackbuilds-1f03a0e8f069db34508633d2df61701eba96368e.tar.gz |
network/heimdal: Updated for version 1.4.
Signed-off-by: Michiel van Wessem <michiel@slackbuilds.org>
Diffstat (limited to 'network/heimdal/doinst.sh')
-rw-r--r-- | network/heimdal/doinst.sh | 39 |
1 files changed, 15 insertions, 24 deletions
diff --git a/network/heimdal/doinst.sh b/network/heimdal/doinst.sh index 8920e52c25..804678c3b8 100644 --- a/network/heimdal/doinst.sh +++ b/network/heimdal/doinst.sh @@ -1,8 +1,3 @@ -# Add heimdal libs to the library search path -if ! grep -q '^/usr/heimdal/lib$' etc/ld.so.conf ; then - echo "/usr/heimdal/lib" >> etc/ld.so.conf -fi - config() { NEW="$1" OLD="$(dirname $NEW)/$(basename $NEW .new)" @@ -16,27 +11,23 @@ config() { # Otherwise, we leave the .new copy for the admin to consider... } -# Keep same perms on rc.heimdal: -if [ -e etc/rc.d/rc.heimdal ]; then - cp -a etc/rc.d/rc.heimdal etc/rc.d/rc.heimdal.new.incoming - cat etc/rc.d/rc.heimdal.new > etc/rc.d/rc.heimdal.new.incoming - mv etc/rc.d/rc.heimdal.new.incoming etc/rc.d/rc.heimdal.new -fi - -# Prepare the new configuration files -for file in \ - etc/rc.d/rc.heimdal.new \ - etc/profile.d/heimdal.sh.new \ - etc/profile.d/heimdal.csh.new ; - do - if [ -e $(dirname $file)/$(basename $file .new) -a -x $(dirname $file)/$(basename $file .new) ]; then - chmod 0755 $file - else - chmod 0644 $file +preserve_perms() { + NEW="$1" + OLD="$(dirname $NEW)/$(basename $NEW .new)" + if [ -e $OLD ]; then + cp -a $OLD ${NEW}.incoming + cat $NEW > ${NEW}.incoming + mv ${NEW}.incoming $NEW fi - config $file -done + config $NEW +} +preserve_perms etc/rc.d/rc.heimdal.new config etc/krb5.conf-sample.new config var/heimdal/kdc.conf-sample.new +# Add heimdal libs to the library search path +if ! grep -q '^/usr/heimdal/lib$' etc/ld.so.conf ; then + echo "/usr/heimdal/lib" >> etc/ld.so.conf +fi + |