improve build system

This commit is contained in:
Jay Robson 2024-04-18 11:31:19 +10:00
parent 6d44c020b3
commit 4beac7a986
5 changed files with 8 additions and 2 deletions

3
.gitmodules vendored
View File

@ -4,3 +4,6 @@
[submodule "matrix-commander"] [submodule "matrix-commander"]
path = matrix-commander path = matrix-commander
url = https://github.com/8go/matrix-commander url = https://github.com/8go/matrix-commander
[submodule "src/cpp-httplib"]
path = src/cpp-httplib
url = https://github.com/yhirose/cpp-httplib

View File

@ -11,7 +11,7 @@ endif()
message("Using cmake flags: ${CMAKE_CXX_FLAGS}") message("Using cmake flags: ${CMAKE_CXX_FLAGS}")
file(GLOB_RECURSE SOURCES src/*.cpp) include(src/CMakeLists.txt)
add_executable(Portfolio ${SOURCES}) add_executable(Portfolio ${SOURCES})
target_link_libraries(Portfolio PUBLIC stdc++ jsoncpp) target_link_libraries(Portfolio PUBLIC stdc++ jsoncpp)

3
src/CMakeLists.txt Normal file
View File

@ -0,0 +1,3 @@
file(GLOB SOURCES src/*.cpp)

View File

@ -1,5 +1,5 @@
#include "../cpp-httplib/httplib.h" #include "cpp-httplib/httplib.h"
#include "files.hpp" #include "files.hpp"
#include "contact.hpp" #include "contact.hpp"