Fix build on non-x86 architectures by conditionally turning off
-march=native. Approved by: portmgr (tier-2 blanket)
This commit is contained in:
parent
498bb75d3a
commit
6521bed65e
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=497619
@ -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>
|
||||
|
11
graphics/opengv/files/extra-patch-CMakeLists.txt
Normal file
11
graphics/opengv/files/extra-patch-CMakeLists.txt
Normal file
@ -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
|
Loading…
Reference in New Issue
Block a user