mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-12-18 04:17:51 +08:00
39 lines
1.3 KiB
CMake
39 lines
1.3 KiB
CMake
vcpkg_minimum_required(VERSION 2022-10-12) # for ${VERSION}
|
|
|
|
string(REPLACE "." "_" release_tag "xmlsec_${VERSION}")
|
|
vcpkg_from_github(
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
|
REPO lsh123/xmlsec
|
|
REF "${release_tag}"
|
|
SHA512 32f297fe47c1b79fb8b58dd12ce49aacb408c9361c140567eda6a49e892025fc227efdc7f85c12fe36b79e658e26ee7b0a1fd770bd6ee5b20e4aa5f9fd0e5288
|
|
HEAD_REF master
|
|
PATCHES
|
|
pkgconfig_fixes.patch
|
|
)
|
|
|
|
file(COPY "${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt" DESTINATION "${SOURCE_PATH}")
|
|
|
|
vcpkg_cmake_configure(
|
|
SOURCE_PATH "${SOURCE_PATH}"
|
|
OPTIONS_DEBUG -DINSTALL_HEADERS_TOOLS=OFF
|
|
)
|
|
|
|
vcpkg_cmake_install()
|
|
vcpkg_cmake_config_fixup(PACKAGE_NAME unofficial-xmlsec)
|
|
vcpkg_fixup_pkgconfig()
|
|
vcpkg_copy_pdbs()
|
|
|
|
if(VCPKG_LIBRARY_LINKAGE STREQUAL dynamic)
|
|
vcpkg_replace_string(
|
|
"${CURRENT_PACKAGES_DIR}/include/xmlsec/xmlsec.h"
|
|
"ifdef XMLSEC_NO_SIZE_T"
|
|
"if 1 //ifdef XMLSEC_NO_SIZE_T"
|
|
)
|
|
endif()
|
|
|
|
# unofficial legacy usage
|
|
file(INSTALL "${CMAKE_CURRENT_LIST_DIR}/xmlsec-config.cmake" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}")
|
|
|
|
file(INSTALL "${CMAKE_CURRENT_LIST_DIR}/usage" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}")
|
|
file(INSTALL "${SOURCE_PATH}/Copyright" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
|