diff --git a/CMakeLists.txt b/CMakeLists.txt index 982eb95..9732d65 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,6 +1,10 @@ -project(advanced_C_standard_library) -cmake_minimum_required(VERSION 3.0) +project(advanced_C_standard_library C) +set_property(GLOBAL PROPERTY C_STANDARD 99) +cmake_minimum_required(VERSION 3.9) include_directories(src) file(GLOB SOURCES "src/*.c") add_executable(test.out ${SOURCES}) -install(TARGETS DESTINATION ${CMAKE_SOURCE_DIR}) +find_program(CCACHE_PROGRAM ccache) +if(CCACHE_PROGRAM) + set(CMAKE_C_COMPILER_LAUNCHER "${CCACHE_PROGRAM}") +endif() diff --git a/src/main.c b/src/main.c index 8b385c4..e921ebe 100644 --- a/src/main.c +++ b/src/main.c @@ -1,4 +1,4 @@ #include int main() { - printf("%s", "baum\n"); + printf("baum\n"); }