Hello,

i've spotted a problem in makepkg's cleanup part if the host is running bash-4.0. As makepkg runs bash with option -e, on bash-4.0 it fails if strip reports an unsupported binary.
The following trivial patch fixes the problem.

Signed-off-by: "Marc - A. Dahlhaus" <[email protected]>

--- pacman-3.2.2.orig/scripts/makepkg.sh.in
+++ pacman-3.2.2/scripts/makepkg.sh.in
@@ -766,11 +766,11 @@ tidy_install() {
        find ${strip_di...@]} -type f 2>/dev/null | while read binary ; do
            case "$(file -biz "$binary")" in
                *application/x-sharedlib*)  # Libraries (.so)
-                    /usr/bin/strip --strip-debug "$binary";;
+                    /usr/bin/strip --strip-debug "$binary" || true;;
                *application/x-archive*)    # Libraries (.a)
-                    /usr/bin/strip --strip-debug "$binary";;
+                    /usr/bin/strip --strip-debug "$binary" || true;;
                *application/x-executable*) # Binaries
-                    /usr/bin/strip "$binary";;
+                    /usr/bin/strip "$binary" || true;;
            esac
        done
    fi

--- pacman-3.2.2.orig/scripts/makepkg.sh.in
+++ pacman-3.2.2/scripts/makepkg.sh.in
@@ -766,11 +766,11 @@ tidy_install() {
                find ${strip_di...@]} -type f 2>/dev/null | while read binary ; 
do
                        case "$(file -biz "$binary")" in
                                *application/x-sharedlib*)  # Libraries (.so)
-                                       /usr/bin/strip --strip-debug "$binary";;
+                                       /usr/bin/strip --strip-debug "$binary" 
|| true;;
                                *application/x-archive*)    # Libraries (.a)
-                                       /usr/bin/strip --strip-debug "$binary";;
+                                       /usr/bin/strip --strip-debug "$binary" 
|| true;;
                                *application/x-executable*) # Binaries
-                                       /usr/bin/strip "$binary";;
+                                       /usr/bin/strip "$binary" || true;;
                        esac
                done
        fi
_______________________________________________
pacman-dev mailing list
[email protected]
http://www.archlinux.org/mailman/listinfo/pacman-dev
  • [pacman-dev] [PATC... Marc - A. Dahlhaus

Reply via email to