Subject: [alpine-devel] [PATCH] abuild: Make default_prepare() always end up in "$builddir".

From: Przemyslaw Pawelczyk <[email-masked]>
Date: Sat, 3 Dec 2016 17:52:25 +0100

So far default_prepare() ended up in "$builddir" only if there were any
patches.  It's better to be more consistent and make such change always.
---
 abuild.in | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/abuild.in b/abuild.in
index e49956b76d04..f56ac033f6a9 100644
--- a/abuild.in
+++ b/abuild.in
@@ -565,10 +565,10 @@ have_patches() {
 
 default_prepare() {
 	local i
+	cd "$builddir" || { error "Is \$builddir set correctly?"; return 1; }
 	if ! have_patches; then
 		return 0
 	fi
-	cd "$builddir" || { error "Is \$builddir set correctly?"; return 1; }
 	for i in $source; do
 		case $i in
 			*.patch)
-- 
2.8.3

---
Unsubscribe:  [email-masked]
Help:         [email-masked]
---