summaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorpommicket <pommicket@gmail.com>2025-09-15 15:11:13 -0400
committerpommicket <pommicket@gmail.com>2025-09-15 15:11:59 -0400
commitdc989291eb6b9b20a25a78f35d6f04968a88ed0b (patch)
treeca494122e2169cbfdb776bfbeadc4b791af03ab9 /CMakeLists.txt
parent627278a0cb84bca7751e97f13d9c235abac678f0 (diff)
Switch to cmake
meson builds "thin" archives by default (this is basically undocumented). You can avoid this by setting install: true supposedly. Whatever I hate it anyways.
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt16
1 files changed, 16 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
new file mode 100644
index 0000000..f14c696
--- /dev/null
+++ b/CMakeLists.txt
@@ -0,0 +1,16 @@
+cmake_minimum_required(VERSION 3.0...3.31)
+project(pom)
+
+if (MSVC)
+ add_compile_options(/W4)
+else()
+ add_compile_options(-Wall -Wextra -Wpedantic -Wshadow)
+endif()
+
+
+add_library(pom-static STATIC pom.c)
+add_library(pom SHARED pom.c)
+add_executable(tests tests/errors.c tests/location.c tests/parsing.c tests/main.c)
+target_include_directories(tests PRIVATE .)
+target_link_libraries(tests pom-static)
+