2023-04-29 07:15:46 +08:00
|
|
|
string(REGEX REPLACE "^([0-9]+)[.]([1-9])\$" "\\1.0\\2" MEDIAINFO_VERSION "${VERSION}")
|
2020-05-13 07:36:56 +08:00
|
|
|
vcpkg_from_github(
|
|
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
|
|
|
REPO MediaArea/MediaInfoLib
|
2023-04-29 07:15:46 +08:00
|
|
|
REF "v${MEDIAINFO_VERSION}"
|
2024-06-03 13:04:10 +08:00
|
|
|
SHA512 6d0f2d7d37aa4fd01fb3e5d82e5b8b6572238b916d2275689f02cc72ed7af54353a324cdff5c2a1d240e586ee33ae8ff8650193dcd353d1fd01bd75234a49c6d
|
2020-05-13 07:36:56 +08:00
|
|
|
HEAD_REF master
|
2023-04-29 07:15:46 +08:00
|
|
|
PATCHES
|
|
|
|
msvc-arm.diff
|
|
|
|
dependencies.diff
|
|
|
|
no-windows-namespace.diff
|
2020-05-13 07:36:56 +08:00
|
|
|
)
|
|
|
|
|
2023-04-29 07:15:46 +08:00
|
|
|
vcpkg_find_acquire_program(PKGCONFIG)
|
|
|
|
|
2021-09-08 12:06:30 +08:00
|
|
|
vcpkg_cmake_configure(
|
|
|
|
SOURCE_PATH "${SOURCE_PATH}/Project/CMake"
|
2020-08-20 12:24:02 +08:00
|
|
|
OPTIONS
|
|
|
|
-DBUILD_ZENLIB=0
|
|
|
|
-DBUILD_ZLIB=0
|
2023-04-29 07:15:46 +08:00
|
|
|
"-DPKG_CONFIG_EXECUTABLE=${PKGCONFIG}"
|
|
|
|
-DCMAKE_REQUIRE_FIND_PACKAGE_PkgConfig=1
|
|
|
|
-DCMAKE_REQUIRE_FIND_PACKAGE_TinyXML=1
|
2020-05-13 07:36:56 +08:00
|
|
|
)
|
2021-09-08 12:06:30 +08:00
|
|
|
vcpkg_cmake_install()
|
2023-04-29 07:15:46 +08:00
|
|
|
vcpkg_cmake_config_fixup(PACKAGE_NAME mediainfolib)
|
2021-12-22 12:05:32 +08:00
|
|
|
vcpkg_fixup_pkgconfig()
|
2023-04-29 07:15:46 +08:00
|
|
|
if(NOT VCPKG_BUILD_TYPE AND VCPKG_TARGET_IS_WINDOWS)
|
|
|
|
vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/debug/lib/pkgconfig/libmediainfo.pc" " -lmediainfo" " -lmediainfod")
|
|
|
|
endif()
|
2020-05-13 07:36:56 +08:00
|
|
|
|
2021-12-22 12:05:32 +08:00
|
|
|
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
|
2020-05-13 07:36:56 +08:00
|
|
|
|
2023-04-29 07:15:46 +08:00
|
|
|
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE")
|