aboutsummaryrefslogtreecommitdiffstats
path: root/main
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2017-03-21 08:09:52 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2017-03-21 08:14:05 +0000
commitefa9dc8cb7febbd7d045354ea7fd7a2287a56664 (patch)
treeaefc5dbd51a45a046285679a2c252fba104e78cb /main
parent1a4d299a0242a02aa0d4843dd9947d4187e70414 (diff)
downloadaports-efa9dc8cb7febbd7d045354ea7fd7a2287a56664.tar.bz2
aports-efa9dc8cb7febbd7d045354ea7fd7a2287a56664.tar.xz
main/abuild: fix runpart
Diffstat (limited to 'main')
-rw-r--r--main/abuild/0001-abuild-fix-runpart.patch62
-rw-r--r--main/abuild/APKBUILD6
2 files changed, 66 insertions, 2 deletions
diff --git a/main/abuild/0001-abuild-fix-runpart.patch b/main/abuild/0001-abuild-fix-runpart.patch
new file mode 100644
index 0000000000..6f6c3eae22
--- /dev/null
+++ b/main/abuild/0001-abuild-fix-runpart.patch
@@ -0,0 +1,62 @@
+From 3b61bfb6445a71208e218828296b8ca3bb65932e Mon Sep 17 00:00:00 2001
+From: Natanael Copa <ncopa@alpinelinux.org>
+Date: Tue, 21 Mar 2017 08:05:44 +0000
+Subject: [PATCH] abuild: fix runpart
+
+we need to run the function for runpart in the same shell, otherwise we
+will lose the global variables set in the split functions.
+---
+ abuild.in | 29 +++++++++++------------------
+ 1 file changed, 11 insertions(+), 18 deletions(-)
+
+diff --git a/abuild.in b/abuild.in
+index 1eede20..903da3a 100644
+--- a/abuild.in
++++ b/abuild.in
+@@ -566,9 +566,9 @@ update_config_guess() {
+ runpart() {
+ local part=$1
+ [ -n "$DEBUG" ] && msg "$part"
+- abuild_function=$part "$abuild_path" \
+- $color_opt $nodeps $force $forceroot $keep $quiet \
+- $install_deps $recursive $upgrade || die "$part failed"
++ trap "die '$part failed'" EXIT
++ $part
++ trap - EXIT
+ }
+
+ # override those in your build script
+@@ -2340,22 +2340,15 @@ controldir="$pkgbasedir"/.control.${subpkgname:-$pkgname}
+
+ trap 'die "Aborted by user"' INT
+
+-if [ "$abuild_function" ]; then
+- _function=$abuild_function
+- abuild_function=
+- $_function
++[ -z "$subpkgdir" ] && set_xterm_title "abuild${CROSS_COMPILE+-$CARCH}: $pkgname"
+
+-else
+- [ -z "$subpkgdir" ] && set_xterm_title "abuild${CROSS_COMPILE+-$CARCH}: $pkgname"
+-
+- if [ -z "$1" ]; then
+- set all
+- fi
+-
+- while [ $# -gt 0 ]; do
+- runpart $1
+- shift
+- done
++if [ -z "$1" ]; then
++ set all
+ fi
+
++while [ $# -gt 0 ]; do
++ runpart $1
++ shift
++done
++
+ cleanup
+--
+2.11.1
+
diff --git a/main/abuild/APKBUILD b/main/abuild/APKBUILD
index 8df61aba20..5f65bf7a5e 100644
--- a/main/abuild/APKBUILD
+++ b/main/abuild/APKBUILD
@@ -2,7 +2,7 @@
pkgname=abuild
pkgver=3.0.0_rc1
_ver=${pkgver%_git*}
-pkgrel=1
+pkgrel=2
pkgdesc="Script to build Alpine Packages"
url="http://git.alpinelinux.org/cgit/abuild/"
arch="all"
@@ -21,6 +21,7 @@ options="suid"
pkggroups="abuild"
source="http://dev.alpinelinux.org/archive/abuild/abuild-$_ver.tar.xz
0001-functions-fix-abuild-A.patch
+ 0001-abuild-fix-runpart.patch
"
builddir="$srcdir/$pkgname-$_ver"
@@ -64,4 +65,5 @@ gems() {
}
sha512sums="48f33e791805d9ec0f1fcfc28d9d2e58c84dc168b1a64e52733eefdc9daf2450c0cea20f9cdf3a61755d7344cc24f801ef0e9954b30881a713885d935a59dc36 abuild-3.0.0_rc1.tar.xz
-eaec95123f4c67fce84ccd190d1de47f27406acd1f600495100bf553b48eb9bf2a91b833a2c0d37c15306014e6972ea5a25134c35fd29be7a8f8574168cbb5a9 0001-functions-fix-abuild-A.patch"
+eaec95123f4c67fce84ccd190d1de47f27406acd1f600495100bf553b48eb9bf2a91b833a2c0d37c15306014e6972ea5a25134c35fd29be7a8f8574168cbb5a9 0001-functions-fix-abuild-A.patch
+1a8094ade46455caf5de84c3e465af492ee3e018e98767cb93e6eea2f83d91feea846b77ee06b70e17395519ebe11ba5cb6add73d49c548b1daca361a4258997 0001-abuild-fix-runpart.patch"