SimpleArchiver/CMakeLists.txt
Stephen Seo 44080e85cc Impl. parser (TODO Fix invalid free crash)
During testing, having at least three positional args cause an invalid
free crash. Should be investigated and fixed.
2024-06-27 11:57:29 +09:00

23 lines
651 B
CMake

cmake_minimum_required(VERSION 3.7)
project(SimpleArchiver C)
set(SimpleArchiver_VERSION 1.0)
set(SimpleArchiver_SOURCES
src/main.c
src/parser.c
)
add_compile_options(
-Wall -Wextra -Wpedantic -Wno-missing-braces
$<$<COMPILE_LANGUAGE:CXX>:-Weffc++>
$<$<CONFIG:DEBUG>:-Og>
)
if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES)
message(STATUS "Setting build type to 'Debug', none was specified.")
set(CMAKE_BUILD_TYPE Debug CACHE STRING "Choose the type of build." FORCE)
set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS "Debug" "Release")
endif()
add_executable(SimpleArchiver ${SimpleArchiver_SOURCES})