[Users] ETK config-stage failure with Macports gcc -- C+11 range-based for statments?

Bernard Kelly physicsbeany at gmail.com
Thu Nov 16 14:23:55 CST 2023


Hi. I tried making a new configuration on my Macbook (MacOS Ventura,
13.6.2) after a gap of several months, and it's now failing the "make
sim-config" step with a complaint about the C++ compiler not being
C++11-compliant -- end of the make config step screen output is below.

I'm using the latest available Macports-supplied GNU compilers
(gcc-mp-13, g++-mp-13, etc.), with the following C & C++ options:

---------- compiler flags -----------
CPP = /opt/local/bin/cpp-mp-13
CC  = /opt/local/bin/gcc-mp-13
CXX = /opt/local/bin/g++-mp-13
CPPFLAGS =
CFLAGS   = -std=c99
CXXFLAGS = -std=c++14
C_LINE_DIRECTIVES = yes
OPTIMISE           = yes
CPP_OPTIMISE_FLAGS = # -DCARPET_OPTIMISE -DNDEBUG
C_OPTIMISE_FLAGS   = -O2 -march=native
CXX_OPTIMISE_FLAGS = -O2 -march=native
OPENMP           = yes
CPP_OPENMP_FLAGS = -fopenmp
C_OPENMP_FLAGS   = -fopenmp
CXX_OPENMP_FLAGS = -fopenmp
WARN           = yes
CPP_WARN_FLAGS = -Wall
C_WARN_FLAGS   = -Wall
CXX_WARN_FLAGS = -Wall
---------- end of compiler flags -----------

Can anyone suggest what's up? The error says that the C++ compiler is
failing to do range-based for statements, but I can compile & run a simple
program with a range-based for statement, so this seems unlikely.

I'm currently on ET_2023-05, but have this problem with ET_2022_11 as well,
and with gcc-mp-12.

Thanks, Bernard

--------------- last bit of screen output ---------
checking if compiler has broken omp collapse... no
checking for getopt_long_only... yes
checking for working const... yes
checking for C inline... inline
checking for C static inline... static inline
checking for C restrict... restrict
checking for C++ restrict... __restrict__
checking for C++ copysign... std::copysign
checking for C++ fpclassify... std::fpclassify
checking for C++ isfinite... std::isfinite
checking for C++ isinf... std::isinf
checking for C++ isnan... std::isnan
checking for C++ isnormal... std::isnormal
checking for C++ signbit... std::signbit
checking for C _Pragma... yes
checking for C function __attribute__((__const__))... yes
checking for C++ function __attribute__((__const__))... yes
checking for C++ member function __attribute__((__const__))... yes
checking for C function __attribute__((__pure__))... yes
checking for C++ function __attribute__((__pure__))... yes
checking for C++ member function __attribute__((__pure__))... yes
checking for C data __attribute__((__common__))... yes
checking for C+ data __attribute__((__common__))... yes
checking for C function __attribute__((__noinline__))... yes
checking for C++ function __attribute__((__noinline__))... yes
checking for C++ member function __attribute__((__noinline__))... yes
checking for C function __attribute__((__always_inline__))... yes
checking for C++ function __attribute__((__always_inline__))... yes
checking for C++ member function __attribute__((__always_inline__))... yes
checking for C __attribute__((__unused__))... yes
checking for C++ __attribute__((__unused__))... yes
checking for C __attribute__((__aligned__(...)))... yes
checking for C++ __attribute__((__aligned__(...)))... yes
checking for C __attribute__((__cold__))... yes
checking for C++ __attribute__((__cold__))... yes
checking for C __attribute__((__hot__))... yes
checking for C++ __attribute__((__hot__))... yes
checking for C __attribute__((__format__(printf, 1, 2)))... yes
checking for C++ __attribute__((__format__(printf, 1, 2)))... yes
checking for C __attribute__((__noreturn__))... yes
checking for C++ __attribute__((__noreturn__))... yes
checking for C __attribute__((__nonnull__))... yes
checking for C++ __attribute__((__nonnull__))... yes
checking for C __attribute__((__returns_nonnull__))... yes
checking for C++ __attribute__((__returns_nonnull__))... yes
checking for C __builtin_expect... yes
checking for C++ __builtin_expect... yes
checking for C __builtin_trap... yes
checking for C++ __builtin_trap... yes
checking for C __builtin_unreachable... no
checking for C++ __builtin_unreachable... no
checking for C __builtin_assume_aligned... yes
checking for C++ __builtin_assume_aligned... yes
checking for C++ static_assert... yes
checking for C++ auto specifier... yes
checking for C++ lambda expressions... yes
checking for C++ range-based for statements... no
Cactus requires a C++11 compiler -- check your C++ compiler and C++
compiler flags

Error reconfiguring sim-config
make: *** [sim-config] Error 2

-- 
------------------------------------------------------------------
Bernard Kelly -- CRESST Assistant Research Scientist, NASA/GSFC
Gravitational Astrophysics Laboratory --- Code 663

Phone: +1 (301) 286-7243 *** Fax: +1 (301) 286-2226
Web: http://science.gsfc.nasa.gov/sed/bio/bernard.j.kelly
ORCID: orcid.org/0000-0002-3326-4454
------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.einsteintoolkit.org/pipermail/users/attachments/20231116/024ef7e0/attachment.htm>


More information about the Users mailing list