diff --git a/CMakeLists.txt b/CMakeLists.txt index f285aa2a..a944af1c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -35,6 +35,8 @@ set(CMAKE_CXX_STANDARD 17) set(CMAKE_CXX_STANDARD_REQUIRED ON) set(CMAKE_EXPORT_COMPILE_COMMANDS ON) +set(CMAKE_C_STANDARD 11) + if(NOT CMAKE_BUILD_TYPE) set(CMAKE_BUILD_TYPE "Release" CACHE STRING "Choose the type of build, options are: Debug Release RelWithDebInfo MinSizeRel." FORCE) endif() diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index b06631df..8637c625 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -48,6 +48,8 @@ #include #include #include +#include +#include /** * From QDlt. diff --git a/src/src.pro b/src/src.pro index a3918dd1..3b42f1ea 100644 --- a/src/src.pro +++ b/src/src.pro @@ -6,7 +6,7 @@ QT_VER_MIN = $$member(QT_VERSION, 1) CONFIG += c++1z *-gcc* { - QMAKE_CFLAGS += -std=gnu99 + QMAKE_CFLAGS += -std=c11 QMAKE_CFLAGS += -Wall QMAKE_CFLAGS += -Wextra #QMAKE_CXXFLAGS += -pedantic