diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..3f927f1 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "extern/argh"] + path = extern/argh + url = https://github.com/adishavit/argh.git diff --git a/CMakeLists.txt b/CMakeLists.txt index 4367b9c..0d05b6e 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,15 +1,22 @@ +cmake_minimum_required(VERSION 3.20) + project( contour-creator LANGUAGES CXX) -find_package(GDAL CONFIG REQUIRED) - add_executable(${PROJECT_NAME} src/HeightMap.cpp src/CellMap.cpp src/main.cpp ) + +# Argh is a simple argrument parser +add_subdirectory(extern/argh) +target_link_libraries(${PROJECT_NAME} PRIVATE argh) + +# Gdal is used for geodata IO +find_package(GDAL CONFIG REQUIRED) +target_link_libraries(${PROJECT_NAME} PRIVATE GDAL::GDAL) + find_package(OpenMP) if(OpenMP_CXX_FOUND) target_link_libraries(${PROJECT_NAME} PUBLIC OpenMP::OpenMP_CXX) -endif() - -target_link_libraries(${PROJECT_NAME} GDAL::GDAL) \ No newline at end of file +endif() \ No newline at end of file diff --git a/extern/argh b/extern/argh new file mode 160000 index 0000000..431bf32 --- /dev/null +++ b/extern/argh @@ -0,0 +1 @@ +Subproject commit 431bf323acd3bb805483491ff277dac5d85772ad