From 723c1247b98f5c2afe78ae3f57d1e5af812c8d71 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gonzalo=20Tornar=C3=ADa?= Date: Wed, 2 Feb 2022 21:18:02 -0300 Subject: [PATCH] nauty: disable native code (illegal instructions) The package currently shipped in void gives me illegal instructions in a nehalem cpu. This commit fixes the issue by disabling native compilation unless a build option is given; also disable popcnt which, although available on nehalem, is not available in baseline x86_64. --- srcpkgs/nauty/template | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/srcpkgs/nauty/template b/srcpkgs/nauty/template index 57025e400999..11ef99f656fa 100644 --- a/srcpkgs/nauty/template +++ b/srcpkgs/nauty/template @@ -1,7 +1,7 @@ # Template file for 'nauty' pkgname=nauty version=2.7r3 -revision=1 +revision=2 wrksrc=${pkgname}${version/./} build_style=gnu-configure make_install_args="includedir=/usr/include/nauty @@ -13,6 +13,12 @@ homepage="https://pallini.di.uniroma1.it/" distfiles="https://pallini.di.uniroma1.it/nauty${version/./}.tar.gz" checksum=4f0665b716a53f7a14ea2ae30059f23d064ce3fe4c12c013404ef6e1ee0b88c2 +build_options="native_build" + +if [ -z "$build_option_native_build" ]; then + configure_args="--enable-generic --disable-popcnt" +fi + nauty-devel_package() { depends="${sourcepkg}>=${version}_${revision} ${makedepends}" short_desc+=" - development files"