Explorar o código

CMakeLists: Explicitly specify -Wall for the non-MSVC case

Ensures that -Wall is always active as a compilation flag.
Lioncash %!s(int64=7) %!d(string=hai) anos
pai
achega
5d0dca73c6
Modificáronse 1 ficheiros con 4 adicións e 1 borrados
  1. 4 1
      src/CMakeLists.txt

+ 4 - 1
src/CMakeLists.txt

@@ -37,7 +37,10 @@ if (MSVC)
     set(CMAKE_EXE_LINKER_FLAGS_DEBUG   "/DEBUG /MANIFEST:NO" CACHE STRING "" FORCE)
     set(CMAKE_EXE_LINKER_FLAGS_RELEASE "/DEBUG /MANIFEST:NO /INCREMENTAL:NO /OPT:REF,ICF" CACHE STRING "" FORCE)
 else()
-    add_compile_options("-Wno-attributes")
+    add_compile_options(
+        -Wall
+        -Wno-attributes
+    )
 
     if (APPLE AND CMAKE_CXX_COMPILER_ID STREQUAL Clang)
         add_compile_options("-stdlib=libc++")