Skip to content

Commit

Permalink
added the toml library to cmakefile
Browse files Browse the repository at this point in the history
  • Loading branch information
DeaSTL committed Oct 27, 2023
1 parent b87c4a2 commit ea02206
Show file tree
Hide file tree
Showing 8 changed files with 26 additions and 17,758 deletions.
8 changes: 7 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,15 @@ FetchContent_Declare(
GIT_REPOSITORY "https://github.com/nlohmann/json.git"
GIT_TAG "origin/master"
)
FetchContent_Declare(
tomlplusplus
GIT_REPOSITORY "https://github.com/marzer/tomlplusplus.git"
GIT_TAG "v3.4.0"
)

FetchContent_MakeAvailable(nlohmann_json)
FetchContent_MakeAvailable(cxxopts)
FetchContent_MakeAvailable(tomlplusplus)

file(GLOB_RECURSE SOURCES RELATIVE ${CMAKE_SOURCE_DIR}
"src/**.cpp"
Expand All @@ -34,7 +40,6 @@ set(HEADER_DIR ${CMAKE_SOURCE_DIR}/include)

message("Sources: ${SOURCES}")

#target_link_libraries(cmaker SHARED cxxopts)
include_directories(include)

if(NOT DEFINED RELEASE)
Expand Down Expand Up @@ -82,6 +87,7 @@ endif()

target_link_libraries(cmaker cxxopts)
target_link_libraries(cmaker nlohmann_json)
target_link_libraries(cmaker tomlplusplus)
set(SOURCE_DIR src)
set(BUILD_DIR build)
set_target_properties(cmaker PROPERTIES RUNTIME_OUTPUT_DIRECTORY build)
Expand Down
Loading

0 comments on commit ea02206

Please sign in to comment.