From 2a480438d5d8f97ee8324ffdf77690e495a4d680 Mon Sep 17 00:00:00 2001 From: q66 Date: Wed, 21 Aug 2019 23:56:15 +0200 Subject: [PATCH] minijail: fix build on ppc64le* Big endian is not supported. --- srcpkgs/minijail/patches/ppc.patch | 16 ++++++++++++++++ srcpkgs/minijail/template | 4 ++++ 2 files changed, 20 insertions(+) create mode 100644 srcpkgs/minijail/patches/ppc.patch diff --git a/srcpkgs/minijail/patches/ppc.patch b/srcpkgs/minijail/patches/ppc.patch new file mode 100644 index 00000000000..4265de4187f --- /dev/null +++ b/srcpkgs/minijail/patches/ppc.patch @@ -0,0 +1,16 @@ +These are defined on ppc* in included headers but their values refer to things +that are in headers which are not included. Additionally, ELF_GREG_TYPE refers +to a typedef, which is not a constant value. So undef them, just like some +others are already undef'd for other platforms above that. + +--- gen_constants-inl.h ++++ gen_constants-inl.h +@@ -24,3 +24,8 @@ + // build errors on such broken systems. + #undef BLKTRACESETUP + #undef FS_IOC_FIEMAP ++#undef ELF_ARCH ++#undef ELF_CLASS ++#undef ELF_DATA ++#undef ELF_GREG_TYPE ++#undef FIOQSIZE diff --git a/srcpkgs/minijail/template b/srcpkgs/minijail/template index e27ab8f0f28..678a8c5a998 100644 --- a/srcpkgs/minijail/template +++ b/srcpkgs/minijail/template @@ -12,6 +12,10 @@ homepage="https://android.googlesource.com/platform/external/minijail" distfiles="https://gitlab.com/chinstrap/minijail/-/archive/linux-v${version}/minijail-linux-v${version}.tar.gz" checksum=29334d1bcd16c1ea09e49cef3b47a000e98be7ffe7fa9a28c8cab81643033612 +if [ "$XBPS_TARGET_ENDIAN" = "be" ]; then + broken="bpf.h:110:2: error: #error Unsupported endianness" +fi + do_install() { vbin minijail0 vmkdir usr/lib