diff options
author | Ismael Luceno | 2021-01-05 22:38:26 +0100 |
---|---|---|
committer | Ismael Luceno | 2021-01-05 22:38:26 +0100 |
commit | a534e919fcbd2f5ec740595b2af31b3d664a82ae (patch) | |
tree | 8cfd174f64f749510f55e6070269f8724623497d /FUNCTIONS | |
parent | c35d6cac38018dcdce16a052c7fe6b17270b3a14 (diff) |
FUNCTIONS: Simplify post-install path fixup
Diffstat (limited to 'FUNCTIONS')
-rwxr-xr-x | FUNCTIONS | 24 |
1 files changed, 8 insertions, 16 deletions
@@ -22,28 +22,20 @@ function qt5_cmake_build() { ## This function automatically fixes any known bad paths #--------------------------------------------------------------------- function default_grimoire_post_install () { + local rc=0 real_default_sorcery_post_install && # currently a no-op if [[ $STAGED_INSTALL == off ]]; then return 0 fi && pushd TRANSL &> /dev/null && - if [[ -d usr/man ]]; then - echo Fixing bad install path: /usr/man && - mv -v usr/man usr/share - fi && - if [[ -d usr/info ]]; then - echo Fixing bad install path: /usr/info && - mv -v usr/info usr/share - fi && - if [[ -d usr/local/man ]]; then - echo Fixing bad install path: /usr/local/man && - mv -v usr/local/man usr/share - fi && - if [[ -d usr/local/info ]]; then - echo Fixing bad install path: /usr/local/info && - mv -v usr/local/info usr/share - fi && + for i in usr{,/local}/{man,info}; do + if [[ -d "$i" ]]; then + echo "Fixing bad install path: /$i" && + mv -v "$i" usr/share + fi || rc=1 + done popd &> /dev/null + return $rc } #--------------------------------------------------------------------- |