From 51bf5125eadc34897049cbe49fb0ded2d3adf1ec Mon Sep 17 00:00:00 2001 From: Chris Cannam Date: Wed, 28 Jan 2015 21:01:25 +0000 Subject: [PATCH] Minor build tweak --- Makefile.ios | 6 +++--- src/system/sysutils.h | 4 ++++ 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/Makefile.ios b/Makefile.ios index ceb5ba9..de9c2a4 100644 --- a/Makefile.ios +++ b/Makefile.ios @@ -1,15 +1,15 @@ CXX := clang++ CC := clang -OPTFLAGS := -DNDEBUG -ffast-math -freciprocal-math -O3 -ftree-vectorize +OPTFLAGS := -ffast-math -freciprocal-math -O3 -ftree-vectorize # For the device -ARCHFLAGS_DEV := -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk -miphoneos-version-min=6 -stdlib=libc++ -arch armv7 -arch arm64 +ARCHFLAGS_DEV := -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk -miphoneos-version-min=6 -stdlib=libc++ -arch armv7 -arch arm64 # Or for the simulator ARCHFLAGS_SIM := -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk -miphoneos-version-min=6 -stdlib=libc++ -arch i386 -arch x86_64 -CXXFLAGS_ANY := $(OPTFLAGS) -I. -Isrc -Irubberband -DMALLOC_IS_ALIGNED -DHAVE_VDSP -DUSE_SPEEX -DUSE_POMMIER_MATHFUN -DNO_THREADING -DNO_THREAD_CHECKS -DNO_TIMING -DNO_TIMING_COMPLETE_NOOP +CXXFLAGS_ANY := $(OPTFLAGS) -I. -Isrc -Irubberband -DMALLOC_IS_ALIGNED -DHAVE_VDSP -DUSE_SPEEX -DUSE_POMMIER_MATHFUN -DNO_THREADING -DNO_THREAD_CHECKS -DNO_TIMING -DNO_TIMING_COMPLETE_NOOP -DNDEBUG CXXFLAGS_DEV := $(ARCHFLAGS_DEV) $(CXXFLAGS_ANY) CXXFLAGS_SIM := $(ARCHFLAGS_SIM) $(CXXFLAGS_ANY) diff --git a/src/system/sysutils.h b/src/system/sysutils.h index 452bbe6..c2aaf51 100644 --- a/src/system/sysutils.h +++ b/src/system/sysutils.h @@ -29,9 +29,13 @@ #define R__ __restrict #endif +#ifdef __clang__ +#define R__ __restrict__ +#else #ifdef __GNUC__ #define R__ __restrict__ #endif +#endif #ifndef R__ #define R__