svn commit: r497619 - in head/graphics/opengv: . files
Mark Linimon
linimon at FreeBSD.org
Wed Apr 3 04:33:37 UTC 2019
Author: linimon
Date: Wed Apr 3 04:33:35 2019
New Revision: 497619
URL: https://svnweb.freebsd.org/changeset/ports/497619
Log:
Fix build on non-x86 architectures by conditionally turning off
-march=native.
Approved by: portmgr (tier-2 blanket)
Added:
head/graphics/opengv/files/
head/graphics/opengv/files/extra-patch-CMakeLists.txt (contents, props changed)
Modified:
head/graphics/opengv/Makefile
Modified: head/graphics/opengv/Makefile
==============================================================================
--- head/graphics/opengv/Makefile Wed Apr 3 04:27:41 2019 (r497618)
+++ head/graphics/opengv/Makefile Wed Apr 3 04:33:35 2019 (r497619)
@@ -26,4 +26,11 @@ do-test:
${SETENV} ${MAKE_ENV} ${MAKE_CMD} ${MAKE_ARGS} ${ALL_TARGET} && \
${SETENV} ${MAKE_ENV} ${MAKE_CMD} ${MAKE_ARGS} test
-.include <bsd.port.mk>
+.include <bsd.port.pre.mk>
+
+# disable march-native on non-x86 archs
+.if ${ARCH} != amd64 && ${ARCH} != i386
+EXTRA_PATCHES+= ${PATCHDIR}/extra-patch-CMakeLists.txt
+.endif
+
+.include <bsd.port.post.mk>
Added: head/graphics/opengv/files/extra-patch-CMakeLists.txt
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/graphics/opengv/files/extra-patch-CMakeLists.txt Wed Apr 3 04:33:35 2019 (r497619)
@@ -0,0 +1,11 @@
+--- CMakeLists.txt.orig 2018-10-25 03:22:02 UTC
++++ CMakeLists.txt
+@@ -35,8 +35,6 @@ ELSE()
+ ELSEIF (CMAKE_SYSTEM_PROCESSOR MATCHES
+ "(arm)|(ARM)|(armhf)|(ARMHF)|(armel)|(ARMEL)")
+ add_definitions (-march=armv7-a)
+- ELSE ()
+- add_definitions (-march=native) #TODO use correct c++11 def once everybody has moved to gcc 4.7 # for now I even removed std=gnu++0x
+ ENDIF()
+ add_definitions (
+ -O3
More information about the svn-ports-head
mailing list