From e62759e5f268b70792431841c546ca793dc6f370 Mon Sep 17 00:00:00 2001 From: Arne Schwabe Date: Sun, 17 Apr 2016 13:34:12 +0200 Subject: [PATCH] Fix C++ standard also on AVR target (#3401 needs c++11) --- radio/src/CMakeLists.txt | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/radio/src/CMakeLists.txt b/radio/src/CMakeLists.txt index 9861dc8b9..cc8b74d97 100644 --- a/radio/src/CMakeLists.txt +++ b/radio/src/CMakeLists.txt @@ -1025,6 +1025,11 @@ else() cmake_force_cxx_compiler(avr-gcc GNU) set(CMAKE_CXX_FLAGS "-mmcu=${MCU} -DF_CPU=16000000UL -O${OPT} -gdwarf-2 -fno-exceptions -flto -fwhole-program -fno-inline-small-functions -mstrict-X ${WARNING_FLAGS}") +# Remove once the minimum cmake version is set to 3.1 in the main CmakeLists.tx +if (${CMAKE_VERSION} VERSION_LESS 3.1.0}) + set(CMAKE_CXX_FLAGS "-std=gnu++11 ${CMAKE_CXX_FLAGS}") +endif() + include_directories(storage gui/${GUI_DIR})