diff options
author | Raghuram Subramani <raghus2247@gmail.com> | 2025-07-30 22:20:35 +0530 |
---|---|---|
committer | Raghuram Subramani <raghus2247@gmail.com> | 2025-07-30 22:20:35 +0530 |
commit | 2453a083540ae51e91e85b25b60cda659abdd70a (patch) | |
tree | b497ca5779790ed1eda32cab5d22701085bfbc2b | |
parent | b99884a48fbba7954638667412796c10d12bfae5 (diff) |
build: build discount along with msg
-rw-r--r-- | CMakeLists.txt | 25 |
1 files changed, 16 insertions, 9 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index ead810f..084d2c5 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,4 +1,6 @@ cmake_minimum_required(VERSION 3.21) +add_subdirectory(discount/cmake) + project(msg C) set(SRC @@ -14,20 +16,16 @@ set(SRC src/util.c ) -add_executable(msg ${SRC}) -target_include_directories(msg PRIVATE include) -target_link_libraries(msg markdown) - set(C_COMPILE_OPTIONS - # -O3 - -Og + -O3 + # -Og -Wall -Wextra - # -Werror + -Werror - -g3 - -glldb + # -g3 + # -glldb -std=c99 @@ -35,6 +33,15 @@ set(C_COMPILE_OPTIONS -Wno-unused-variable ) +add_executable(msg ${SRC}) +target_include_directories(msg PRIVATE include) + +target_include_directories(msg PRIVATE discount) +target_link_libraries(msg libmarkdown) + +target_compile_options(libmarkdown PRIVATE + $<$<COMPILE_LANGUAGE:C>: -w> +) target_compile_options(msg PRIVATE $<$<COMPILE_LANGUAGE:C>: ${C_COMPILE_OPTIONS}> ) |