vcpkg/ports/podofo/portfile.cmake

57 lines
1.7 KiB
CMake
Raw Normal View History

[LibLZMA] automatic configuration (#6000) * [LibLZMA] add a config-generated by CMake * bump control files of LibLZMA and dependent ports * [tiff] use proper liblzma target [OpenCV] add an explicit dependency on LibLZMA for static linking * [liblzma] fix header install path * [LibLZMA] avoid using targets in old symbols * fixes for windows-static and trying to see if CI is happier with a share/lib folder written in lowercase * [LibLZMA] use only modern CMake language, remove patch in favour of target public definition * [lzma] put symbols in cmake cache * [libxmlpp] remove CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS regression * [lzma] fix header install path * [liblzma] install wrapper to force config mode * [liblzma] remove function check inside cmake config since we know it will pass * [liblzma] wrapper fix * [tiff,geotiff] general cleanup and patch fixes * [libgeotiff] remove debug tools * [tesseract] modernize * [tiff] fix also tiff_library symbol * [pdal,libgeotiff] better library integration * [tiff] restore using unix i/o on UWP, since it was working... for sure win32 one cannot work * [tiff] enable lzma also on uwp, since it works and is requested by many dependencies * [selene] enable build on arm/arm64-windows, which was surely broken before * [lzma] uniform naming with cmake 3.14 * [podofo] fix regression, it requires openssl which was disabled in dependencies * [many ports] remove unnecessary mods * [boost-iostream] chmod * [openssl] fix regression due to missing architecture * [podofo] fix regression on uwp due to missing include * [libpq] explicitly fail on UWP, it should avoid being marked as regression * [shiva] fix regression on linux
2019-05-29 07:58:00 +08:00
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO podofo/podofo
REF "${VERSION}"
2023-10-03 11:24:45 +08:00
SHA512 cbbd183cd940345f9b077b7da140414c27badc70fdf754e2f3c6f0e51c25072de46d7fe312b014c0eab359bd03e9dca0283260db00f079c5014e268d5c5ef5c9
)
2017-05-08 19:45:27 +08:00
2023-05-31 09:28:05 +08:00
vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
FEATURES
fontconfig CMAKE_REQUIRE_FIND_PACKAGE_Fontconfig
INVERTED_FEATURES
fontconfig CMAKE_DISABLE_FIND_PACKAGE_Fontconfig
)
string(COMPARE EQUAL "${VCPKG_LIBRARY_LINKAGE}" "static" PODOFO_BUILD_STATIC)
file(REMOVE "${SOURCE_PATH}/cmake/modules/FindOpenSSL.cmake")
file(REMOVE "${SOURCE_PATH}/cmake/modules/FindZLIB.cmake")
vcpkg_cmake_configure(
SOURCE_PATH "${SOURCE_PATH}"
OPTIONS
2023-05-31 09:28:05 +08:00
${FEATURE_OPTIONS}
-DPKG_CONFIG_FOUND=true # enable pc file for shared linkage
-DPODOFO_BUILD_LIB_ONLY=1
-DPODOFO_BUILD_STATIC=${PODOFO_BUILD_STATIC}
2023-05-31 09:28:05 +08:00
-DCMAKE_DISABLE_FIND_PACKAGE_Libidn=ON
)
vcpkg_cmake_install()
vcpkg_copy_pdbs()
vcpkg_replace_string( "${CURRENT_PACKAGES_DIR}/share/${PORT}/podofo-config.cmake"
2023-05-31 09:28:05 +08:00
"# Generated by CMake"
"include(CMakeFindDependencyMacro)
find_dependency(Freetype)
find_dependency(JPEG)
find_dependency(LibXml2)
find_dependency(OpenSSL)
2023-05-31 09:28:05 +08:00
find_dependency(PNG)
find_dependency(TIFF)
find_dependency(ZLIB)
if(\"${CMAKE_REQUIRE_FIND_PACKAGE_Fontconfig}\")
find_dependency(Fontconfig)
endif()
\n# Generated by CMake")
vcpkg_cmake_config_fixup()
2023-05-31 09:28:05 +08:00
vcpkg_fixup_pkgconfig()
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
2017-05-08 19:45:27 +08:00
# Handle copyright
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/COPYING")
file(INSTALL "${CMAKE_CURRENT_LIST_DIR}/usage" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}")