diff options
author | saturneric <[email protected]> | 2024-01-25 10:51:02 +0000 |
---|---|---|
committer | saturneric <[email protected]> | 2024-01-25 11:30:12 +0000 |
commit | 41f1dd4d69c589d7b49fcb36b45ab149d5ebceda (patch) | |
tree | 24464bd33d0d7cf964d2091579cc1004f1f97651 | |
parent | fix: try to solve bugs at universal file operations (diff) | |
download | GpgFrontend-41f1dd4d69c589d7b49fcb36b45ab149d5ebceda.tar.gz GpgFrontend-41f1dd4d69c589d7b49fcb36b45ab149d5ebceda.zip |
fix: buddle libarchive as submodule
-rw-r--r-- | .gitmodules | 3 | ||||
-rw-r--r-- | src/CMakeLists.txt | 4 | ||||
-rw-r--r-- | src/core/CMakeLists.txt | 5 | ||||
-rw-r--r-- | third_party/CMakeLists.txt | 2 | ||||
m--------- | third_party/libarchive | 0 |
5 files changed, 5 insertions, 9 deletions
diff --git a/.gitmodules b/.gitmodules index e05878f7..0ca4ffd2 100644 --- a/.gitmodules +++ b/.gitmodules @@ -10,3 +10,6 @@ [submodule "third_party/googletest"] path = third_party/googletest url = https://github.com/google/googletest.git +[submodule "third_party/libarchive"] + path = third_party/libarchive + url = https://github.com/libarchive/libarchive.git diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 71734127..a225f616 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -171,10 +171,6 @@ if (BUILD_APPLICATION) list(APPEND ALL_RUNTIME_DEP_PATH_LIST ${_libDllPath}) unset(_libDllPath) - file(GLOB _libDllPath "${_libDllBinPath}/libarchive-*.dll") - list(APPEND ALL_RUNTIME_DEP_PATH_LIST ${_libDllPath}) - - unset(_libDllPath) file(GLOB _libDllPath "${_libDllBinPath}/libassuan-*.dll") list(APPEND ALL_RUNTIME_DEP_PATH_LIST ${_libDllPath}) diff --git a/src/core/CMakeLists.txt b/src/core/CMakeLists.txt index ed12ad01..54c3bf41 100644 --- a/src/core/CMakeLists.txt +++ b/src/core/CMakeLists.txt @@ -76,11 +76,6 @@ endif () target_link_libraries(gpgfrontend_core PRIVATE spdlog) # link libarchive -if(APPLE) - set(LibArchive_INCLUDE_DIR "/usr/local/opt/libarchive/include") -endif() -find_package(LibArchive REQUIRED) -target_include_directories(gpgfrontend_core PRIVATE ${LibArchive_INCLUDE_DIR}) target_link_libraries(gpgfrontend_core PRIVATE archive) # link Qt core diff --git a/third_party/CMakeLists.txt b/third_party/CMakeLists.txt index 1ab18df8..df8bca3a 100644 --- a/third_party/CMakeLists.txt +++ b/third_party/CMakeLists.txt @@ -29,6 +29,8 @@ set(JSON_BuildTests OFF CACHE INTERNAL "") add_subdirectory(spdlog EXCLUDE_FROM_ALL) +add_subdirectory(libarchive EXCLUDE_FROM_ALL) + # not working at macOS if(NOT APPLE) set(MI_SECURE ON) diff --git a/third_party/libarchive b/third_party/libarchive new file mode 160000 +Subproject 60f086b37fc40952530d385e9f7a05ebec3dd9a |