aboutsummaryrefslogtreecommitdiffstats
path: root/main/apk-tools
diff options
context:
space:
mode:
authorTimo Teräs <timo.teras@iki.fi>2017-02-28 16:03:52 +0200
committerTimo Teräs <timo.teras@iki.fi>2017-02-28 16:03:52 +0200
commitf965a9b1661f09c3ba69d55cc124c129f372f798 (patch)
treed2cfd0e4249309f569d37097ee6ff25210a4a223 /main/apk-tools
parent07ba0967a724b5c787bb76e2ad21e8a4cecb027d (diff)
downloadaports-f965a9b1661f09c3ba69d55cc124c129f372f798.tar.bz2
aports-f965a9b1661f09c3ba69d55cc124c129f372f798.tar.xz
main/apk-tools: upgrade to 2.7.0, modernize aport
Diffstat (limited to 'main/apk-tools')
-rw-r--r--main/apk-tools/0001-add-s390x-headers.patch25
-rw-r--r--main/apk-tools/0001-tar-return-correct-error-for-short-read-of-tar-archi.patch37
-rw-r--r--main/apk-tools/APKBUILD37
3 files changed, 13 insertions, 86 deletions
diff --git a/main/apk-tools/0001-add-s390x-headers.patch b/main/apk-tools/0001-add-s390x-headers.patch
deleted file mode 100644
index b05da4979c..0000000000
--- a/main/apk-tools/0001-add-s390x-headers.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From 24636f5277d6279f7740a46ed446d1bc763c7e91 Mon Sep 17 00:00:00 2001
-From: "Tuan M. Hoang" <tmhoang@flatglobe.org>
-Date: Sun, 20 Nov 2016 22:39:44 +0700
-Subject: [PATCH] add s390x headers
-
----
- src/apk_defines.h | 2 ++
- 1 file changed, 2 insertions(+)
-
-diff --git a/src/apk_defines.h b/src/apk_defines.h
-index 9b2e904..7215360 100644
---- a/src/apk_defines.h
-+++ b/src/apk_defines.h
-@@ -95,6 +95,8 @@ extern char **apk_argv;
- #define APK_DEFAULT_ARCH "armel"
- #elif defined(__aarch64__) && __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
- #define APK_DEFAULT_ARCH "aarch64"
-+#elif defined(__s390x__)
-+#define APK_DEFAULT_ARCH "s390x"
- #else
- #error APK_DEFAULT_ARCH not detected for this architecture
- #endif
---
-2.10.2
-
diff --git a/main/apk-tools/0001-tar-return-correct-error-for-short-read-of-tar-archi.patch b/main/apk-tools/0001-tar-return-correct-error-for-short-read-of-tar-archi.patch
deleted file mode 100644
index fa54f797f5..0000000000
--- a/main/apk-tools/0001-tar-return-correct-error-for-short-read-of-tar-archi.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From ca368916e0333bf24cdcbdbe42130ec6a92c3f6e Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Timo=20Ter=C3=A4s?= <timo.teras@iki.fi>
-Date: Thu, 5 Jan 2017 16:14:44 +0200
-Subject: [PATCH] tar: return correct error for short read of tar archive
-
----
- src/archive.c | 11 ++++++++---
- 1 file changed, 8 insertions(+), 3 deletions(-)
-
-diff --git a/src/archive.c b/src/archive.c
-index e86a53a..07b33e2 100644
---- a/src/archive.c
-+++ b/src/archive.c
-@@ -105,12 +105,17 @@ static ssize_t tar_entry_read(void *stream, void *ptr, size_t size)
-
- if (size > teis->bytes_left)
- size = teis->bytes_left;
-- if (size == 0)
-- return 0;
-+ if (size == 0)
-+ return 0;
-
- r = teis->tar_is->read(teis->tar_is, ptr, size);
-- if (r < 0)
-+ if (r <= 0) {
-+ /* If inner stream returned zero (end-of-stream), we
-+ * are getting short read, because tar header indicated
-+ * more was to be expected. */
-+ if (r == 0) return -ECONNABORTED;
- return r;
-+ }
-
- teis->bytes_left -= r;
- if (teis->csum == NULL)
---
-2.11.0
-
diff --git a/main/apk-tools/APKBUILD b/main/apk-tools/APKBUILD
index aebff6a366..e90145de4d 100644
--- a/main/apk-tools/APKBUILD
+++ b/main/apk-tools/APKBUILD
@@ -1,36 +1,29 @@
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=apk-tools
-pkgver=2.6.8
-pkgrel=2
+pkgver=2.7.0
+pkgrel=0
pkgdesc="Alpine Package Keeper - package manager for alpine"
subpackages="$pkgname-static"
depends=
makedepends_build=""
-makedepends_host="zlib-dev libressl libressl-dev libfetch-dev"
+makedepends_host="zlib-dev libressl libressl-dev libfetch-dev linux-headers"
makedepends="$makedepends_build $makedepends_host"
if [ "$CBUILD" = "$CHOST" ]; then
subpackages="$subpackages lua5.2-apk:luaapk"
makedepends="$makedepends lua5.2-dev"
fi
source="http://dev.alpinelinux.org/archive/$pkgname/$pkgname-$pkgver.tar.xz
- 0001-add-s390x-headers.patch
- 0001-tar-return-correct-error-for-short-read-of-tar-archi.patch
"
url="http://git.alpinelinux.org/cgit/apk-tools/"
arch="all"
license=GPL2
-_builddir="$srcdir/$pkgname-$pkgver"
+builddir="$srcdir/$pkgname-$pkgver"
prepare() {
- cd "$_builddir"
+ default_prepare || return 1
+ cd "$builddir"
sed -i -e 's:-Werror::' Make.rules
- for i in $source; do
- case $i in
- *.patch) msg "$i"; patch -p1 -i "$srcdir"/$i || return 1
- esac
- done
-
echo "FULL_VERSION=$pkgver-r$pkgrel" > config.mk || return 1
if [ "$CBUILD" = "$CHOST" ]; then
echo "LUAAPK=YesPlease" >> config.mk
@@ -41,13 +34,17 @@ prepare() {
}
build() {
- cd "$_builddir"
+ cd "$builddir"
make || return 1
make static || return 1
}
+check() {
+ make check
+}
+
package() {
- cd "$_builddir"
+ cd "$builddir"
make DESTDIR="$pkgdir" install
install -d "$pkgdir"/var/lib/apk \
"$pkgdir"/var/cache/misc \
@@ -84,12 +81,4 @@ luaapk() {
mv "$pkgdir"/usr/lib "$subpkgdir"/usr/lib/
}
-md5sums="cc3efedf3047c256f13549ba58df3291 apk-tools-2.6.8.tar.xz
-f77a0ce3b4a67cbefed14c3a3ebf253f 0001-add-s390x-headers.patch
-b15f4cb8d0e9507a5a3fb84bb39f3deb 0001-tar-return-correct-error-for-short-read-of-tar-archi.patch"
-sha256sums="83f5cf9f0e75c19004a67150819eae2d4c859236b6c9c04d34d5b6968925f0d3 apk-tools-2.6.8.tar.xz
-db8519fd21f7b302e1b339d037b5b02cbcefcf197891b45af5362d17d8d66bd5 0001-add-s390x-headers.patch
-5754067cba52370e8522ea52e9491f0c73063ca06a5f12cad8c5b1d4e08a39d5 0001-tar-return-correct-error-for-short-read-of-tar-archi.patch"
-sha512sums="03fb42616335de9edaf3e44fd64a8d1c5dd8b0f25b7f3b176940b751a6547b8be153549f0cee9a5d65491025f6747799b6f5ba22b15d850593d499c07b5cc4c6 apk-tools-2.6.8.tar.xz
-7ab0a174c86613631d85cf6e51925b4a5a7ce42b6b02db2166bc5629517edf42d6abc1f9404621161e647b1d61f01641bc4ef91060e98e20b7a4bd4a9758fab5 0001-add-s390x-headers.patch
-3f84b930ffc37f1aba9b1b6da31a494ab694ef4d2dd458b470bdebef6cd4155a7840832d12f2f5dd486a31d1c16ea054977638c511d60569565f66a0c9c0a9a0 0001-tar-return-correct-error-for-short-read-of-tar-archi.patch"
+sha512sums="e6bb4bdada76f5d18b9a6ec8981b4619dd2e2a517ff3248693a5b2743286e2ee605dabf775bcdbbab5dff479334662b11c3c9c296cd17e3db4fbdcdc2efe9ea7 apk-tools-2.7.0.tar.xz"