From 65f23c87750dc188c794a1aa64d1ca38259bbc75 Mon Sep 17 00:00:00 2001 From: khooyp Date: Wed, 11 Jan 2012 16:55:23 +0000 Subject: [PATCH] Conditionally enable -march=native, since it doesn't work in GCC on OS X. git-svn-id: https://stp-fast-prover.svn.sourceforge.net/svnroot/stp-fast-prover/trunk/stp@1496 e59a4935-1847-0410-ae03-e826735625c1 --- scripts/Makefile.common | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/scripts/Makefile.common b/scripts/Makefile.common index 17e8051..ee197e9 100644 --- a/scripts/Makefile.common +++ b/scripts/Makefile.common @@ -10,7 +10,13 @@ -include $(TOP)/scripts/config.info -OPTIMIZE = -O3 -DNDEBUG -march=native -fomit-frame-pointer # Optimization +# use -march=native if it works correctly (it's broken in GCC on OS X) +ifeq ($(shell $(CXX) -march=native -E - < /dev/null >/dev/null 2>&1 && echo 1),1) + OPTIMIZE_MARCH_NATIVE = -march=native +endif + +# Optimization +OPTIMIZE = -O3 -DNDEBUG -fomit-frame-pointer $(OPTIMIZE_MARCH_NATIVE) #OPTIMIZE = -O3 -g # Debug # To enable 128-bit indices in the array propagators. Put the INDICES_128BITS -- 2.47.3