summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorAllan McRae <allan@archlinux.org>2016-01-25 06:23:16 +0100
committerAllan McRae <allan@archlinux.org>2016-01-25 06:23:16 +0100
commit47ea63ff3b9818e4b2edc94155345691f6472452 (patch)
tree15c8f7ed9e0ff6b014ba246f6d2246ab597e37ef /scripts
parent765e29b67cf139efb1e88d428f95f71b5f0f01bb (diff)
downloadpacman-47ea63ff3b9818e4b2edc94155345691f6472452.tar.gz
pacman-47ea63ff3b9818e4b2edc94155345691f6472452.tar.xz
makepkg: do not run prepare() and pkgver() with --repackage
Bug introduced with commit 8454daa7. Reported-by: Zuyi Hu <hzy068808@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
Diffstat (limited to 'scripts')
-rw-r--r--scripts/makepkg.sh.in40
1 files changed, 21 insertions, 19 deletions
diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in
index 753621b8..80b95f41 100644
--- a/scripts/makepkg.sh.in
+++ b/scripts/makepkg.sh.in
@@ -2192,28 +2192,30 @@ mkdir -p "$srcdir"
chmod a-s "$srcdir"
cd_safe "$srcdir"
-if (( NOEXTRACT && ! VERIFYSOURCE )); then
- warning "$(gettext "Using existing %s tree")" "\$srcdir/"
-elif (( !REPKG )); then
- download_sources
- check_source_integrity
- (( VERIFYSOURCE )) && exit 0 # $E_OK
+if (( !REPKG )); then
+ if (( NOEXTRACT && ! VERIFYSOURCE )); then
+ warning "$(gettext "Using existing %s tree")" "\$srcdir/"
+ else
+ download_sources
+ check_source_integrity
+ (( VERIFYSOURCE )) && exit 0 # $E_OK
- if (( CLEANBUILD )); then
- msg "$(gettext "Removing existing %s directory...")" "\$srcdir/"
- rm -rf "$srcdir"/*
- fi
+ if (( CLEANBUILD )); then
+ msg "$(gettext "Removing existing %s directory...")" "\$srcdir/"
+ rm -rf "$srcdir"/*
+ fi
- extract_sources
-fi
+ extract_sources
+ fi
-if (( PKGVERFUNC )); then
- update_pkgver
- basever=$(get_full_version)
- check_build_status
-fi
-if (( PREPAREFUNC )); then
- run_prepare
+ if (( PKGVERFUNC )); then
+ update_pkgver
+ basever=$(get_full_version)
+ check_build_status
+ fi
+ if (( PREPAREFUNC )); then
+ run_prepare
+ fi
fi
if (( NOBUILD )); then