From 47313acee48029bfdd1ee34bf1947b962ccff283 Mon Sep 17 00:00:00 2001 From: Allan McRae Date: Tue, 31 Jan 2012 23:25:19 +1000 Subject: makepkg: Fix non-writable SRCPKGDEST error message Provide a helpful error message for when creating a source tarball and SRCPKGDEST is not writable. Fixes FS#28197. Signed-off-by: Allan McRae Signed-off-by: Dan McGee --- scripts/makepkg.sh.in | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'scripts/makepkg.sh.in') diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in index e51f9ede..f407e67b 100644 --- a/scripts/makepkg.sh.in +++ b/scripts/makepkg.sh.in @@ -2048,6 +2048,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} -- cgit v1.2.3-24-g4f1b From 17e71fc908df4a5df48c9054f6c0621d3c7b80ea Mon Sep 17 00:00:00 2001 From: Mantas Mikulėnas Date: Fri, 3 Feb 2012 15:22:44 +0200 Subject: makepkg: add forgotten newline in help output Signed-off-by: Allan McRae Signed-off-by: Dan McGee --- scripts/makepkg.sh.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'scripts/makepkg.sh.in') diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in index f407e67b..7faaac2b 100644 --- a/scripts/makepkg.sh.in +++ b/scripts/makepkg.sh.in @@ -1829,7 +1829,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" -- cgit v1.2.3-24-g4f1b From 0fdf0b19ced256d395366b24a669960416341d37 Mon Sep 17 00:00:00 2001 From: Andrew Gregory Date: Sat, 4 Feb 2012 09:06:05 -0500 Subject: makepkg.sh.in - fix remove_deps test for deps to be removed Signed-off-by: Dan McGee --- scripts/makepkg.sh.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'scripts/makepkg.sh.in') diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in index 7faaac2b..29ed4f2f 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 -- cgit v1.2.3-24-g4f1b From b7c06d6d678ebe6a434b2387c3bda14647113f32 Mon Sep 17 00:00:00 2001 From: Andrew Gregory Date: Sat, 4 Feb 2012 09:07:02 -0500 Subject: makepkg.sh.in - if both -r and -i are provided, only remove makedeps Signed-off-by: Dan McGee --- scripts/makepkg.sh.in | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'scripts/makepkg.sh.in') diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in index 29ed4f2f..6a1f3141 100644 --- a/scripts/makepkg.sh.in +++ b/scripts/makepkg.sh.in @@ -2299,7 +2299,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 @@ -2307,6 +2307,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 -- cgit v1.2.3-24-g4f1b