Skip to content

Commit

Permalink
Disable HAVE_FRAMEWORK_ACCELERATE for compilers which fail to compile…
Browse files Browse the repository at this point in the history
… with it

g++-10 and g++-11 throw compiler errors in builds with the
Accelerate framework, so disable it for all GNU compilers
before version 12 (which still has to be tested).

Signed-off-by: Stefan Weil <[email protected]>
  • Loading branch information
stweil committed Sep 6, 2021
1 parent 35dee46 commit e5e12f2
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/arch/simddetect.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,12 @@
#include "simddetect.h"
#include "tprintf.h" // for tprintf

#if !defined(__clang__) && defined(__GNUC__) && (__GNUC__ < 12)
// The GNU compiler g++ fails to compile with the Accelerate framework
// (tested with versions 10 and 11), so unconditionally disable it.
#undef HAVE_FRAMEWORK_ACCELERATE
#endif

#if defined(HAVE_FRAMEWORK_ACCELERATE)

// Use Apple Accelerate framework.
Expand Down

0 comments on commit e5e12f2

Please sign in to comment.