wok diff slitaz-base-files/receipt @ rev 18472
ghostscript, libv4l, slitaz-base-files: fix installation (thanks llev)
ghostscript: fix package upgrades;
libv4l: check multiple preloads in case of upgrade, not add preload if installation not finished/fails;
slitaz-base-files: not to overwrite real sudo.
ghostscript: fix package upgrades;
libv4l: check multiple preloads in case of upgrade, not add preload if installation not finished/fails;
slitaz-base-files: not to overwrite real sudo.
author | Aleksej Bobylev <al.bobylev@gmail.com> |
---|---|
date | Mon Oct 05 01:10:26 2015 +0300 (2015-10-05) |
parents | 014b3427b79d |
children | 815908f41087 |
line diff
1.1 --- a/slitaz-base-files/receipt Mon Aug 24 01:14:05 2015 +0300 1.2 +++ b/slitaz-base-files/receipt Mon Oct 05 01:10:26 2015 +0300 1.3 @@ -102,24 +102,25 @@ 1.4 # 1.5 pre_install() 1.6 { 1.7 - local root="$1" 1.8 - cp -a $root/etc $root/tmp/etc.bak 2>/dev/null 1.9 + cp -a "$1/etc" "$1/tmp/etc.bak" 2>/dev/null 1.10 + [ -x "$1/usr/bin/sudo" ] && mv "$1/usr/bin/sudo" "$1/usr/bin/sudo.orig" 1.11 # Remove old /var/run symlink 1.12 - rm -f $root/var/run 1.13 + rm -f "$1/var/run" 1.14 } 1.15 1.16 post_install() 1.17 { 1.18 - local root="$1" 1.19 - cp -a $root/tmp/etc.bak/* $root/etc 2>/dev/null 1.20 - rm -rf $root/tmp/etc.bak 1.21 + cp -a "$1/tmp/etc.bak"/* "$1/etc" 2>/dev/null 1.22 + rm -r "$1/tmp/etc.bak" 1.23 + 1.24 + [ -x "$1/usr/bin/sudo.orig" ] && mv -f "$1/usr/bin/sudo.orig" "$1/usr/bin/sudo" 1.25 1.26 # Reset permission. 1.27 - chmod 640 $root/etc/shadow 1.28 - chmod 640 $root/etc/gshadow 1.29 + chmod 640 "$1/etc/shadow" 1.30 + chmod 640 "$1/etc/gshadow" 1.31 1.32 - if ! grep -q audio $root/etc/group; then 1.33 - chroot $root/ /bin/addgroup -g 20 audio 1.34 + if ! grep -q audio "$1/etc/group"; then 1.35 + chroot "$1/" /bin/addgroup -g 20 audio 1.36 fi 1.37 } 1.38