2023-05-10 07:56:27 +08:00
|
|
|
vcpkg_from_github(
|
|
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
|
|
|
REPO openzim/libzim
|
2023-05-14 00:45:03 +08:00
|
|
|
REF "${VERSION}"
|
2023-12-12 17:31:45 +08:00
|
|
|
SHA512 55d18535d677d3249c8331ceac1acd4afa650de1f61a0aa3ffc1c98ca2a395bc657c774d01780f1a2c2aedd7d9c5d2e7d9f5e717ed879de84dc6d1be6accfe5e
|
2023-05-10 07:56:27 +08:00
|
|
|
HEAD_REF main
|
|
|
|
PATCHES
|
2023-05-14 00:45:03 +08:00
|
|
|
cross-builds.diff
|
|
|
|
dllexport.diff
|
2023-12-12 17:31:45 +08:00
|
|
|
subdirs.diff
|
2023-05-10 07:56:27 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
set(EXTRA_OPTIONS "")
|
|
|
|
|
|
|
|
if(NOT "xapian" IN_LIST FEATURES)
|
|
|
|
list(APPEND EXTRA_OPTIONS "-Dwith_xapian=false")
|
|
|
|
endif()
|
|
|
|
|
|
|
|
vcpkg_configure_meson(
|
|
|
|
SOURCE_PATH "${SOURCE_PATH}"
|
|
|
|
OPTIONS
|
|
|
|
-Dexamples=false
|
|
|
|
${EXTRA_OPTIONS}
|
|
|
|
)
|
|
|
|
|
2023-05-14 00:45:03 +08:00
|
|
|
vcpkg_install_meson()
|
2023-05-10 07:56:27 +08:00
|
|
|
|
|
|
|
vcpkg_copy_pdbs()
|
|
|
|
|
|
|
|
vcpkg_fixup_pkgconfig()
|
|
|
|
|
2023-12-12 17:31:45 +08:00
|
|
|
if(VCPKG_LIBRARY_LINKAGE STREQUAL "dynamic")
|
|
|
|
vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/include/zim/zim.h" "defined(LIBZIM_IMPORT_DLL)" "1")
|
|
|
|
endif()
|
|
|
|
|
2023-05-10 07:56:27 +08:00
|
|
|
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")
|
|
|
|
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/COPYING")
|