New package: openbsd-file-6.2

This commit is contained in:
Juan RP 2020-01-30 16:04:01 +01:00
parent 74648fd560
commit aca67913f2
3 changed files with 55 additions and 0 deletions

View file

@ -0,0 +1,10 @@
--- file.c.orig 2020-01-30 15:16:15.402746181 +0100
+++ file.c 2020-01-30 15:16:29.514898212 +0100
@@ -19,6 +19,7 @@
#include <sys/types.h>
#include <sys/mman.h>
#include <sys/stat.h>
+#include <sys/sysmacros.h>
#include <err.h>
#include <errno.h>

View file

@ -0,0 +1,19 @@
--- seccomp-sandbox.c.orig 2020-01-30 15:59:29.517540311 +0100
+++ seccomp-sandbox.c 2020-01-30 16:03:43.046273793 +0100
@@ -40,6 +40,16 @@
#define SECCOMP_AUDIT_ARCH AUDIT_ARCH_I386
#elif defined __x86_64__ || defined __amd64__
#define SECCOMP_AUDIT_ARCH AUDIT_ARCH_X86_64
+#elif defined __aarch64__
+#define SECCOMP_AUDIT_ARCH AUDIT_ARCH_AARCH64
+#elif defined __arm__
+#define SECCOMP_AUDIT_ARCH AUDIT_ARCH_ARM
+#elif defined __powerpc64__ && defined __LITTLE_ENDIAN__
+#define SECCOMP_AUDIT_ARCH AUDIT_ARCH_PPC64LE
+#elif defined __powerpc64__
+#define SECCOMP_AUDIT_ARCH AUDIT_ARCH_PPC64
+#elif defined __powerpc__
+#define SECCOMP_AUDIT_ARCH AUDIT_ARCH_PPC
#endif
#endif /* SECCOMP_AUDIT_ARCH */

View file

@ -0,0 +1,26 @@
# Template file for 'openbsd-file'
pkgname=openbsd-file
version=6.2
revision=1
wrksrc="file-${version}"
build_style=gnu-configure
configure_args="--program-prefix=openbsd-"
hostmakedepends="automake libtool"
short_desc="Portable version of OpenBSD's privsep/sandboxed file(1) utility"
maintainer="Juan RP <xtraeme@gmail.com>"
license="ISC"
homepage="https://github.com/brynet/file/"
distfiles="https://github.com/brynet/file/archive/v${version}.tar.gz"
checksum=f6bf601f513bd83038e343bbd93b7982f373669a2ffa76dc52d48fa7251515b2
if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
CFLAGS="-DREG_STARTEND=0"
makedepends+=" musl-legacy-compat"
fi
pre_configure() {
autoreconf -fi
}
post_install() {
vlicense LICENSE
}