aboutsummaryrefslogtreecommitdiffstats
path: root/testing/bfs
diff options
context:
space:
mode:
authorLeo <thinkabit.ukim@gmail.com>2019-07-03 06:45:29 -0300
committerLeo <thinkabit.ukim@gmail.com>2019-07-08 12:43:05 -0300
commit36e370f00f203733496927c978991ab1880074ba (patch)
tree81b42f10ee458c9c18be6846b566f9a2cde27de6 /testing/bfs
parentbc78782f6252fcba7ca8f9ca38c61cc64478b96f (diff)
downloadaports-36e370f00f203733496927c978991ab1880074ba.tar.bz2
aports-36e370f00f203733496927c978991ab1880074ba.tar.xz
testing/bfs: upgrade to 1.5
Diffstat (limited to 'testing/bfs')
-rw-r--r--testing/bfs/APKBUILD13
-rw-r--r--testing/bfs/no-statx.patch31
2 files changed, 39 insertions, 5 deletions
diff --git a/testing/bfs/APKBUILD b/testing/bfs/APKBUILD
index 70a1653490..f85119b156 100644
--- a/testing/bfs/APKBUILD
+++ b/testing/bfs/APKBUILD
@@ -1,17 +1,19 @@
# Contributor: dai9ah <dai9ah@protonmail.com>
# Maintainer: dai9ah <dai9ah@protonmail.com>
pkgname=bfs
-pkgver=1.4.1
+pkgver=1.5
pkgrel=0
pkgdesc="Breadth-first variant of the UNIX find command"
url="https://github.com/tavianator/bfs"
arch="all"
license="0BSD"
-makedepends="acl-dev libcap-dev linux-headers"
-checkdepends="bash"
+makedepends="acl-dev libcap-dev linux-headers attr-dev"
+checkdepends="bash acl"
subpackages="$pkgname-doc"
options="!checkroot"
-source="$pkgname-$pkgver.tar.gz::https://github.com/tavianator/bfs/archive/$pkgver.tar.gz"
+source="$pkgname-$pkgver.tar.gz::https://github.com/tavianator/bfs/archive/$pkgver.tar.gz
+ no-statx.patch
+ "
build() {
make
@@ -25,4 +27,5 @@ package() {
make DESTDIR="$pkgdir" install
}
-sha512sums="ffe5f703c6a8b66f94f861ba804c46547780eb33b05a7fcae9fca0ee3947579c8e8a88e2a0c5637f6b33b0618272435e9269bb516c0cacb49a6c669ce07aec6a bfs-1.4.1.tar.gz"
+sha512sums="13e79ce1d488f5ed9338020b1502c78cf9141ec7eceacc2fb79da23a81403b10b17c07116408dbf0b6bef7744dd547a8749d98bc485fda70665a07fac7e5f561 bfs-1.5.tar.gz
+010666234db1bae05f42288eaf4943d4677ec363e5142839c958bee0ed10d7a994bec255d9efee05d63f58e7c91e060a4ca06306aa1774bb47068daf1ef34e85 no-statx.patch"
diff --git a/testing/bfs/no-statx.patch b/testing/bfs/no-statx.patch
new file mode 100644
index 0000000000..b737b5e0c8
--- /dev/null
+++ b/testing/bfs/no-statx.patch
@@ -0,0 +1,31 @@
+From 71a1b65ba926ff9c6db3cb671580b5491db0bd97 Mon Sep 17 00:00:00 2001
+From: Tavian Barnes <tavianator@tavianator.com>
+Date: Fri, 5 Jul 2019 19:11:20 -0400
+Subject: [PATCH] stat: Treat EPERM like ENOSYS for statx()
+
+On some configurations (e.g. old Docker with the default seccomp()
+profile), statx() fails with EPERM. Consider this to mean statx() is
+unsupported, as EPERM is not a documented error code in normal
+operation.
+
+Possible fix for https://github.com/alpinelinux/aports/pull/9277
+---
+ stat.c | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/stat.c b/stat.c
+index e3d5400..a2e2c8d 100644
+--- a/stat.c
++++ b/stat.c
+@@ -282,7 +282,9 @@ static int bfs_stat_explicit(int at_fd, const char *at_path, int at_flags, enum
+
+ if (has_statx) {
+ int ret = bfs_statx_impl(at_fd, at_path, at_flags, flags, buf);
+- if (ret != 0 && errno == ENOSYS) {
++ // EPERM is commonly returned in a seccomp() sandbox that does
++ // not allow statx()
++ if (ret != 0 && (errno == ENOSYS || errno == EPERM)) {
+ has_statx = false;
+ } else {
+ return ret;
+