From 9184c4f501cd2bbbb12ac42213e6a897e4886023 Mon Sep 17 00:00:00 2001 From: Wilson Snyder Date: Sun, 26 Sep 2021 16:19:46 -0400 Subject: [PATCH] Fix cygwin compile error due to missing -std=gnu++14 (#3149) --- Changes | 1 + configure.ac | 10 +++++++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/Changes b/Changes index 20d4bc238..adc725eb1 100644 --- a/Changes +++ b/Changes @@ -20,6 +20,7 @@ Verilator 4.213 devel * Fix removing if statement with side effect in condition (#3131). [Alexander Grobman] * Fix --waiver-output for multiline warnings (#2429) (#3141). [Keith Colbert] * Fix crash on clang 12/13 (#3148). [Kouping Hsu] +* Fix cygwin compile error due to missing -std=gnu++14 (#3149). [sunkim68] Verilator 4.212 2021-09-01 diff --git a/configure.ac b/configure.ac index 6057b5019..18d728957 100644 --- a/configure.ac +++ b/configure.ac @@ -347,13 +347,17 @@ AC_SUBST(CFG_CXXFLAGS_PROFILE) # Flag to select newest language standard supported # Macros work such that first option that passes is the one we take # Currently enabled c++14 due to packaged SystemC dependency -# c++17 is the newest that Verilator supports -# c++03 is the oldest that Verilator supports +# c++14 is the newest that Verilator is regressed to support +# c++11 is the oldest that Verilator supports +# gnu is requried for Cygwin to compile verilated.h successfully +#_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=gnu++20) #_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=c++20) +#_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=gnu++17) #_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=c++17) +_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=gnu++14) _MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=c++14) +_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=gnu++11) _MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=c++11) -_MY_CXX_CHECK_SET(CFG_CXXFLAGS_STD_NEWEST,-std=c++03) AC_SUBST(CFG_CXXFLAGS_STD_NEWEST) # Flags for compiling Verilator internals including parser, and Verilated files