From d6c4e538b8b40b34761fbaa0ae1e064836f36fed Mon Sep 17 00:00:00 2001 From: Greatwolf Date: Mon, 12 Dec 2016 15:16:39 -0800 Subject: [PATCH] Turn on warnings. Compile using C99 mode for long long, declaration initialization and other useful stuff. --- CMakeLists.txt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index d273ade..b81bd88 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -12,6 +12,10 @@ find_package(PythonLibs REQUIRED) include_directories(${LUA_INCLUDE_DIR}) include_directories(${PYTHON_INCLUDE_DIR}) +if (CMAKE_C_COMPILER_ID STREQUAL "GNU") + set(CMAKE_C_FLAGS "-Wall -pedantic -std=c99 ${CMAKE_C_FLAGS}") +endif () + add_subdirectory(src) add_library(python MODULE $)