From 8cdef6d4b9d32540a9594c8510a61aaed7414ed8 Mon Sep 17 00:00:00 2001 From: Nathan Owens Date: Sun, 13 Dec 2020 12:57:34 -0600 Subject: [PATCH] splint: Fix cross-build --- srcpkgs/splint/template | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/srcpkgs/splint/template b/srcpkgs/splint/template index 4e3a93eaf29..5420a6cfc4b 100644 --- a/srcpkgs/splint/template +++ b/srcpkgs/splint/template @@ -1,7 +1,7 @@ # Template file for 'splint' pkgname=splint version=3.1.2 -revision=4 +revision=5 wrksrc="${pkgname}-${version}.orig" build_style=gnu-configure hostmakedepends="flex" @@ -13,9 +13,16 @@ license="GPL-2" distfiles="${DEBIAN_SITE}/main/s/splint/${pkgname}_${version}+dfsg.orig.tar.xz" checksum=51cd7ba978a366ae1ededac2b927058fd5f45d5455e5a9d640b75ab4e45b748a disable_parallel_build=yes -nocross=yes post_patch() { vsed -i 's/__pid_t/pid_t/g' src/osd.c vsed -i -e '/RM.*[.]tab[.]h/d' src/Makefile.am src/Makefile.in } + +post_configure() { + # Test tries to run program. If cross-building + # this will fail. + if [ "$CROSS_BUILD" ]; then + vsed -i '/SUBDIRS/s|test||' Makefile + fi +}