Files
cmake-examples/01-basic/G-compile-flags/CMakeLists.txt
Thom Troy b81da6f68b Update to minimum CMake 3.5
And modernise some examples.
2018-03-18 17:23:57 +00:00

15 lines
362 B
CMake

cmake_minimum_required(VERSION 3.5)
# Set a default C++ compile flag
set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DEX2" CACHE STRING "Set C++ Compiler Flags" FORCE)
# Set the project name
project (compile_flags)
# Add an executable
add_executable(cmake_examples_compile_flags main.cpp)
target_compile_definitions(cmake_examples_compile_flags
PRIVATE EX3
)