index : pacman | |
Archlinux32 fork of pacman | gitolite user |
summaryrefslogtreecommitdiff |
author | Dave Reisner <dreisner@archlinux.org> | 2011-11-21 23:03:33 -0500 |
---|---|---|
committer | Dan McGee <dan@archlinux.org> | 2011-11-30 22:28:13 -0600 |
commit | a521cea96f24ba9d060e019c74ccbe63a1e06392 (patch) | |
tree | 2832f79d80754c4559a7a6a99c39173fd075f11d /scripts/makepkg.sh.in | |
parent | 15aa57d51b4f7f49d55912650ed13ce573f1e946 (diff) |
-rw-r--r-- | scripts/makepkg.sh.in | 16 |
diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in index f39e9d1e..7cf4844d 100644 --- a/scripts/makepkg.sh.in +++ b/scripts/makepkg.sh.in @@ -506,15 +506,17 @@ remove_deps() { # check for packages removed during dependency install (e.g. due to conflicts) # removing all installed packages is risky in this case - if [[ -n $(comm -23 <(printf "%s\n" "${original_pkglist[@]}") \ - <(printf "%s\n" "${current_pkglist[@]}")) ]]; then - warning "$(gettext "Failed to remove installed dependencies.")" - return 0 + if [[ -n $(grep -xvFf <(printf '%s\n' "${current_packagelist[@]}") \ + <(printf '%s\n' "${original_packagelist[@]}") ) ]]; then + warning "$(gettext "Failed to remove installed dependencies.")" + return 0 fi - local deplist=($(comm -13 <(printf "%s\n" "${original_pkglist[@]}") \ - <(printf "%s\n" "${current_pkglist[@]}"))) - (( ${#deplist[@]} == 0 )) && return + local deplist + if ! deplist=($(grep -xvFf <(printf "%s\n" "${original_pkglist[@]}") \ + <(printf "%s\n" "${current_pkglist[@]}"))); then + return + fi msg "Removing installed dependencies..." # exit cleanly on failure to remove deps as package has been built successfully |