vcpkg/ports/kf5crash/portfile.cmake
Dawid Wróbel 960264885a
[kf5crash] fix cmake.in to allow consumption by static builds (#19179)
* [kf5crash] fix cmake.in to allow consumption by static builds

* [kf5crash] update versions

* [kf5crash] kcrash is supported on Win and macOS, too

* [kf5crash] update versions

* [kf5crash] replace deprecated functions

* [kf5crash] update versions

* [kf5crash] don't overzealously delete folders

* [kf5crash] update versions

* [kf5crash] proactively disable docs

* [kf5crash] use semVer

* [kf5crash] update versions

* [kf5crash] remove extraneous options

* [kf5crash] update versions

* [kf5crash] wrap paths in quotes

* [kf5crash] update versions

* [kf5crash] remove bin folders in static build

* [kf5crash] update versions

* [kf5crash] rename patch file

* [kf5crash] update versions

* [kf5crash] add PACKAGE_NAME to vcpkg_cmake_config_fixup

* [kf5crash] update versions
2021-09-03 16:41:20 -07:00

32 lines
1.1 KiB
CMake

vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO KDE/kcrash
REF v5.84.0
SHA512 db37a481e0d34e0024cabd77c22680171fa383ea300c56c73f807380fd818263d27f36fb012fc6604b462dbf9374db39bab94c4dc2c3bff488ac9812d01eb2dd
HEAD_REF master
PATCHES
support_static_builds.patch # https://invent.kde.org/frameworks/kcrash/-/merge_requests/23
)
vcpkg_cmake_configure(
SOURCE_PATH ${SOURCE_PATH}
DISABLE_PARALLEL_CONFIGURE
OPTIONS
-DBUILD_TESTING=OFF
)
vcpkg_cmake_install()
vcpkg_cmake_config_fixup(PACKAGE_NAME KF5Crash CONFIG_PATH lib/cmake/KF5Crash)
vcpkg_copy_pdbs()
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/bin/data")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/etc")
if(VCPKG_LIBRARY_LINKAGE STREQUAL "static")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/bin" "${CURRENT_PACKAGES_DIR}/debug/bin")
endif()
file(INSTALL "${SOURCE_PATH}/LICENSES/" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}/copyright")