Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/scripts/makepkg.sh.in
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2012-02-06 05:50:48 -0600
committerDan McGee <dan@archlinux.org>2012-02-06 05:50:48 -0600
commitf55be4897799c5a6dcb454455ad9edcfc36f8495 (patch)
treedd87b34de4b85f307d5dd05f6d576aadc3ad3697 /scripts/makepkg.sh.in
parentb488f229d2ec4f2e4b9e746d68422460ca664715 (diff)
parentb7c06d6d678ebe6a434b2387c3bda14647113f32 (diff)
Merge branch 'maint'
Conflicts: lib/libalpm/alpm_list.c
Diffstat (limited to 'scripts/makepkg.sh.in')
-rw-r--r--scripts/makepkg.sh.in15
1 files changed, 12 insertions, 3 deletions
diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in
index 82742554..ba96e843 100644
--- a/scripts/makepkg.sh.in
+++ b/scripts/makepkg.sh.in
@@ -519,7 +519,7 @@ remove_deps() {
local deplist
deplist=($(grep -xvFf <(printf "%s\n" "${original_pkglist[@]}") \
<(printf "%s\n" "${current_pkglist[@]}") || true))
- if [[ -n deplist ]]; then
+ if [[ -z deplist ]]; then
return
fi
@@ -1838,7 +1838,7 @@ usage() {
echo
printf -- "$(gettext "Usage: %s [options]")\n" "$0"
echo
- printf -- "$(gettext "Options:")"
+ printf -- "$(gettext "Options:")\n"
printf -- "$(gettext " -A, --ignorearch Ignore incomplete %s field in %s")\n" "arch" "$BUILDSCRIPT"
printf -- "$(gettext " -c, --clean Clean up work files after build")\n"
printf -- "$(gettext " -d, --nodeps Skip all dependency checks")\n"
@@ -2058,6 +2058,11 @@ fi
SRCPKGDEST=${_SRCPKGDEST:-$SRCPKGDEST}
SRCPKGDEST=${SRCPKGDEST:-$startdir} #default to $startdir if undefined
+if (( SOURCEONLY )) && [[ ! -w $SRCPKGDEST ]]; then
+ error "$(gettext "You do not have write permission to store source tarballs in %s.")" "$SRCPKGDEST"
+ plain "$(gettext "Aborting...")"
+ exit 1
+fi
PKGEXT=${_PKGEXT:-$PKGEXT}
SRCEXT=${_SRCEXT:-$SRCEXT}
@@ -2305,7 +2310,7 @@ if (( NODEPS || ( (NOBUILD || REPKG) && !DEP_BIN ) )); then
warning "$(gettext "Skipping dependency checks.")"
fi
elif type -p "${PACMAN%% *}" >/dev/null; then
- if (( RMDEPS )); then
+ if (( RMDEPS && ! INSTALL )); then
original_pkglist=($(run_pacman -Qq)) # required by remove_dep
fi
deperr=0
@@ -2313,6 +2318,10 @@ elif type -p "${PACMAN%% *}" >/dev/null; then
msg "$(gettext "Checking runtime dependencies...")"
resolve_deps ${depends[@]} || deperr=1
+ if (( RMDEPS && INSTALL )); then
+ original_pkglist=($(run_pacman -Qq)) # required by remove_dep
+ fi
+
msg "$(gettext "Checking buildtime dependencies...")"
resolve_deps ${makedepends[@]} || deperr=1