diff options
author | Axel Beckert <abe@deuxchevaux.org> | 2016-01-31 20:20:28 +0100 |
---|---|---|
committer | Axel Beckert <abe@deuxchevaux.org> | 2016-01-31 20:22:02 +0100 |
commit | da1b680be1e3307cc2c2de34b81be554f4a32be6 (patch) | |
tree | e3b967df4179d87f45aeb6704ba1cc6f9d0acedb /debian/zsh.postinst | |
parent | 0013070a348a68ced5894522501ad3b17d26e7fb (diff) | |
download | zsh-da1b680be1e3307cc2c2de34b81be554f4a32be6.tar.gz zsh-da1b680be1e3307cc2c2de34b81be554f4a32be6.zip |
Remove usage of alternatives system for zsh, rzsh and zsh-static
This also fixes installation together with usrmerge, which fiddles
with the directory layout and makes /bin a symlink to /usr/bin against
all Unix tradition and violating FHS.
Closes: #768079
Diffstat (limited to 'debian/zsh.postinst')
-rw-r--r-- | debian/zsh.postinst | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/debian/zsh.postinst b/debian/zsh.postinst index 2ba220230..843a8f357 100644 --- a/debian/zsh.postinst +++ b/debian/zsh.postinst @@ -18,15 +18,20 @@ case "$1" in ;; esac -update-alternatives --remove zsh /usr/bin/zsh +# ksh alternatives update-alternatives --remove ksh /usr/bin/zsh update-alternatives --remove ksh /bin/zsh4 -update-alternatives --install /bin/zsh zsh /bin/zsh5 51 \ - --slave /usr/bin/zsh zsh-usrbin /bin/zsh5 -update-alternatives --install /bin/rzsh rzsh /bin/zsh5 51 \ - --slave /usr/share/man/man1/rzsh.1.gz rzsh.1.gz /usr/share/man/man1/zsh.1.gz -update-alternatives --remove zsh /bin/zsh4 -update-alternatives --remove rzsh /bin/zsh4 + +# Remove alternatives system for zsh in general +update-alternatives --remove zsh /bin/zsh5 +update-alternatives --remove rzsh /bin/rzsh5 + +# New hardcoded symlinks which unfortunately can't be shipped inside +# the package itself since some people want to merge /bin and /usr/bin +# against FHS and all Unix tradition. +if [ ! -e /usr/bin/zsh -a ! -L /usr/bin/zsh ]; then + ln -s /bin/zsh /usr/bin/zsh +fi #DEBHELPER# |