1
0
mirror of synced 2024-11-28 09:30:51 +01:00

build: Install Database files from subdirectory in offline builds (#737)

Signed-off-by: Colin Kinloch <colin.kinloch@collabora.com>

Signed-off-by: Colin Kinloch <colin.kinloch@collabora.com>
Co-authored-by: Colin Kinloch <colin.kinloch@collabora.com>
This commit is contained in:
Colin Kinloch 2022-09-13 21:34:33 +01:00 committed by GitHub
parent d1468984e7
commit 9fa6d82775
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -392,6 +392,12 @@ function(downloadImHexPatternsFiles dest)
FetchContent_Populate(imhex_patterns)
else ()
# Maybe patterns are cloned to a subdirectory
set(imhex_patterns_SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/ImHex-Patterns")
endif ()
if (EXISTS ${imhex_patterns_SOURCE_DIR})
set(PATTERNS_FOLDERS_TO_INSTALL constants encodings includes patterns magic)
foreach (FOLDER ${PATTERNS_FOLDERS_TO_INSTALL})
install(DIRECTORY "${imhex_patterns_SOURCE_DIR}/${FOLDER}" DESTINATION ${dest})