Skip to content

Commit

Permalink
Add FileLoader library to thirdparty project
Browse files Browse the repository at this point in the history
  - Add FileLoader to CMake build
  • Loading branch information
scorpioluck20 committed Jun 12, 2023
1 parent 59a2252 commit 1ac4f4b
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -152,3 +152,7 @@
[submodule "zlib"]
path = zlib
url = https://github.com/madler/zlib.git
[submodule "FileLoader"]
path = FileLoader
url = ../FileLoader.git

1 change: 1 addition & 0 deletions FileLoader
Submodule FileLoader added at 4ef9d0
19 changes: 19 additions & 0 deletions build/CommonTargets.CMake
Original file line number Diff line number Diff line change
Expand Up @@ -342,6 +342,25 @@ set(_FINDPACKAGE_MNN_LIBRARY_DIR "${CMAKE_CURRENT_BINARY_DIR}/MNN/lib")
set(_FINDPACKAGE_MNN_INCLUDE_DIR "${CMAKE_CURRENT_BINARY_DIR}/MNN/include")
include_directories(${_FINDPACKAGE_MNN_INCLUDE_DIR})

# --------------------------------------------------------
# Build FileLoader
ExternalProject_Add(FileLoader
PREFIX FileLoader
SOURCE_DIR "${THIRDPARTY_DIR}/FileLoader"
CMAKE_CACHE_ARGS
-DCMAKE_INSTALL_PREFIX:PATH=${CMAKE_CURRENT_BINARY_DIR}/FileLoader
-DBUILD_FILELOADER_DIR:PATH=${CMAKE_CURRENT_BINARY_DIR}/FileLoader
-DMNN_INCLUDE_DIR:PATH=${_FINDPACKAGE_MNN_INCLUDE_DIR}
-DMNN_LIBRARY_DIR:PATH=${_FINDPACKAGE_MNN_LIBRARY_DIR}
-DTESTING:BOOL=OFF
${_CMAKE_COMMON_BUILD_PARAMS}
DEPENDS MNN
)

set(_FINDPACKAGE_FILELOADER_CONFIG_DIR "${CMAKE_CURRENT_BINARY_DIR}/FileLoader/lib/cmake/mnn")
set(_FINDPACKAGE_FILELOADER_LIBRARY_DIR "${CMAKE_CURRENT_BINARY_DIR}/FileLoader/lib")
set(_FINDPACKAGE_FILELOADER_INCLUDE_DIR "${CMAKE_CURRENT_BINARY_DIR}/FileLoader/include")

# --------------------------------------------------------
# builds ipfs-lite-cpp
ExternalProject_Add(ipfs-lite-cpp
Expand Down

0 comments on commit 1ac4f4b

Please sign in to comment.