git: cb7689bed31a - main - math/libsemigroups: Add NATIVE option

From: Yuri Victorovich <yuri_at_FreeBSD.org>
Date: Fri, 21 Jul 2023 08:03:16 UTC
The branch main has been updated by yuri:

URL: https://cgit.FreeBSD.org/ports/commit/?id=cb7689bed31a3b881b0b5dec93e882daa7d6fec8

commit cb7689bed31a3b881b0b5dec93e882daa7d6fec8
Author:     Yuri Victorovich <yuri@FreeBSD.org>
AuthorDate: 2023-07-21 08:01:09 +0000
Commit:     Yuri Victorovich <yuri@FreeBSD.org>
CommitDate: 2023-07-21 08:03:11 +0000

    math/libsemigroups: Add NATIVE option
    
    PR:             272499
    Approved by:    thierry@ (maintainer)
---
 math/libsemigroups/Makefile | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/math/libsemigroups/Makefile b/math/libsemigroups/Makefile
index 5f7d6b21856b..11cdf8e22fd6 100644
--- a/math/libsemigroups/Makefile
+++ b/math/libsemigroups/Makefile
@@ -24,12 +24,17 @@ CONFIGURE_ARGS=	--enable-fmt --with-external-fmt=yes	\
 USE_LDCONFIG=	yes
 TEST_TARGET=	check
 
+OPTIONS_DEFINE=	NATIVE
+
 .include <bsd.port.pre.mk>
 
 .if ${ARCH} != amd64
 CONFIGURE_ARGS+=	--disable-hpcombi
 .endif
 
+post-patch-NATIVE-off:
+	@${REINPLACE_CMD} -e 's/-march=native/-march=default/' ${WRKSRC}/m4/ax_check_hpcombi.m4
+
 pre-configure:
 .if ${ARCH} == amd64
 	${REINPLACE_CMD} -e 's|$$srcdir/extern/HPCombi|${LOCALBASE}/share/HPCombi|'	\