devel/py-intbitset: Patch out march/mtune/-O3 (Respect CFLAGS)

ports r476958 added BROKEN to non-x86 ARCH's due to:

fails to compile: the clang compiler does not support -march=core2

Ports must respect user CFLAGS, and beside this port appending its own flags,
overriding system/ports supplied CFLAGS, was also adding march/mtune flags,
the former of which was set to an x86 specific CPU.

This change patches out these flags to address the issue.

While I'm here, level up port compliance (strip shared libraries)

Approved by:	portmgr (blanket, framework compliance)
MFH:		2018Q3
This commit is contained in:
Kubilay Kocak 2018-08-12 05:00:27 +00:00
parent 26403766d5
commit 21bd3d9735
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=476961
2 changed files with 17 additions and 0 deletions

View file

@ -2,6 +2,7 @@
PORTNAME= intbitset PORTNAME= intbitset
DISTVERSION= 2.3.0 DISTVERSION= 2.3.0
PORTREVISION= 1
CATEGORIES= devel python CATEGORIES= devel python
MASTER_SITES= CHEESESHOP MASTER_SITES= CHEESESHOP
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
@ -22,6 +23,9 @@ TEST_DEPENDS= ${PYTHON_PKGNAMEPREFIX}nose>=0:devel/py-nose@${PY_FLAVOR}
USES= python USES= python
USE_PYTHON= cython distutils autoplist USE_PYTHON= cython distutils autoplist
post-install:
${STRIP_CMD} ${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}/intbitset.so
do-test: do-test:
@cd ${WRKSRC} && ${PYTHON_CMD} ${PYDISTUTILS_SETUP} test @cd ${WRKSRC} && ${PYTHON_CMD} ${PYDISTUTILS_SETUP} test

View file

@ -0,0 +1,13 @@
# Respect CFLAGS, remove x86 specific -march tuning which fails on !x86 archs
# https://svnweb.freebsd.org/changeset/ports/476958
--- setup.py.orig 2018-08-12 04:50:38 UTC
+++ setup.py
@@ -48,7 +48,6 @@ setup(
ext_modules=[
Extension("intbitset",
["intbitset/intbitset.c", "intbitset/intbitset_impl.c"],
- extra_compile_args=['-O3', '-march=core2', '-mtune=native']
# For debug -> '-ftree-vectorizer-verbose=2'
)
],