# Requires CMake version 3.16 cmake_minimum_required(VERSION 3.16) # Set the project name and the language # CXX means C++ project(panic LANGUAGES CXX) # Uses C++11 set(CMAKE_CXX_STANDARD 11) # This makes it so it uses C++11, and fails if now found. set(CMAKE_CXX_STANDARD_REQUIRED ON) # Makes sure it uses basic options # -std=c++11 instead of -std-gnu++11 set(CMAKE_CXX_EXTENSIONS OFF) # This finds all the .cpp files in the src/ folder # and it's subfolders. # This is saved in the variale PANIC_SOURCES file(GLOB_RECURSE PANIC_SOURCES CONFIGURE_DEPENDS src/*.cpp ) # Creates an executable called "panic" # It's build from main.cpp and all scr/ add_executable(panic main.cpp ${PANIC_SOURCES} ) # This finds all the .hpp files in the include/ folder # and it's subfolders. target_include_directories(panic PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}/include )