Skip to content
This repository has been archived by the owner on Jun 18, 2024. It is now read-only.

Commit

Permalink
Move all dependencies to their own cmake files
Browse files Browse the repository at this point in the history
  • Loading branch information
SpaghettDev committed Jan 26, 2024
1 parent 189d5b7 commit bdf29d9
Show file tree
Hide file tree
Showing 7 changed files with 26 additions and 1,979 deletions.
4 changes: 4 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -52,12 +52,16 @@ set(BUILD_SHARED_LIBS OFF)
set(BUILD_TESTING OFF)
set(BUILD_EXAMPLES OFF)
include(cmake/libsndfile.cmake)
include(cmake/portable-file-dialogs.cmake)
include(cmake/subprocess.cmake)

target_include_directories(${PROJECT_NAME} PRIVATE
${nhjson_SOURCE_DIR}/single_include
${discord-rpc_SOURCE_DIR}/include
${gdr_SOURCE_DIR}/include/gdr
${libsndfile_SOURCE_DIR}/include
${portable-file-dialogs_SOURCE_DIR}
${subprocess_SOURCE_DIR}/include
)

target_link_libraries(${PROJECT_NAME} discord-rpc sndfile)
10 changes: 10 additions & 0 deletions cmake/portable-file-dialogs.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
include(FetchContent)

FetchContent_Declare(
portable-file-dialogs
GIT_REPOSITORY https://github.com/samhocevar/portable-file-dialogs.git
GIT_TAG 7f852d88a480020d7f91957cbcefe514fc95000c
GIT_PROGRESS TRUE
)
message("Fetching portable-file-dialogs")
FetchContent_MakeAvailable(portable-file-dialogs)
10 changes: 10 additions & 0 deletions cmake/subprocess.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
include(FetchContent)

FetchContent_Declare(
subprocess
GIT_REPOSITORY https://github.com/SpaghettDev/subprocess.git
GIT_TAG 7a641a92eb73e8f39be4d0402efc2c46d5bd1b47
GIT_PROGRESS TRUE
)
message("Fetching subprocess")
FetchContent_MakeAvailable(subprocess)
2 changes: 1 addition & 1 deletion src/Macrobot/Clickpacks.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@


#include "../GUI/GUI.h"
#include "../portable-file-dialogs.h"
#include <portable-file-dialogs.h>
#include <filesystem>

#include <Geode/Geode.hpp>
Expand Down
2 changes: 1 addition & 1 deletion src/Macrobot/Record.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
#include <queue>
#include <vector>
#include <unordered_map>
#include "../subprocess.hpp"
#include <subprocess.hpp>
#include <string>
#include <Geode/modify/GJBaseGameLayer.hpp>

Expand Down
Loading

0 comments on commit bdf29d9

Please sign in to comment.