2019-07-16 07:33:11 +08:00
|
|
|
vcpkg_check_linkage(ONLY_STATIC_LIBRARY)
|
|
|
|
|
|
|
|
vcpkg_from_github(
|
|
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
|
|
|
REPO mohabouje/WinToast
|
2023-11-17 08:49:36 +08:00
|
|
|
REF "v${VERSION}"
|
|
|
|
SHA512 b9e34595049851754dafe506681af494f59edf94a4324c20aaeadea25b9ed0abac87e93384d2080c327dbbdd22441800e9af7c5ce6728d7cc1464796a83cffbd
|
2019-07-16 07:33:11 +08:00
|
|
|
HEAD_REF master
|
|
|
|
)
|
|
|
|
|
2022-01-12 06:27:35 +08:00
|
|
|
vcpkg_cmake_configure(
|
|
|
|
SOURCE_PATH "${SOURCE_PATH}"
|
2023-11-17 08:49:36 +08:00
|
|
|
OPTIONS
|
|
|
|
-DWINTOASTLIB_BUILD_EXAMPLES=OFF
|
|
|
|
-DWINTOASTLIB_QT_ENABLED=OFF
|
2019-07-16 07:33:11 +08:00
|
|
|
)
|
|
|
|
|
2023-11-17 08:49:36 +08:00
|
|
|
vcpkg_cmake_build(TARGET WinToast)
|
|
|
|
|
|
|
|
if (NOT DEFINED VCPKG_BUILD_TYPE OR VCPKG_BUILD_TYPE STREQUAL "release")
|
|
|
|
file(INSTALL "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-rel/${VCPKG_TARGET_STATIC_LIBRARY_PREFIX}WinToast${VCPKG_TARGET_STATIC_LIBRARY_SUFFIX}" DESTINATION "${CURRENT_PACKAGES_DIR}/lib")
|
|
|
|
endif()
|
|
|
|
if (NOT DEFINED VCPKG_BUILD_TYPE OR VCPKG_BUILD_TYPE STREQUAL "debug")
|
|
|
|
file(INSTALL "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-dbg/${VCPKG_TARGET_STATIC_LIBRARY_PREFIX}WinToast${VCPKG_TARGET_STATIC_LIBRARY_SUFFIX}" DESTINATION "${CURRENT_PACKAGES_DIR}/debug/lib")
|
|
|
|
endif()
|
|
|
|
file(INSTALL "${SOURCE_PATH}/include/wintoastlib.h" DESTINATION "${CURRENT_PACKAGES_DIR}/include")
|
2019-07-16 07:33:11 +08:00
|
|
|
|
2023-11-17 08:49:36 +08:00
|
|
|
configure_file("${CMAKE_CURRENT_LIST_DIR}/Config.cmake.in" "${CURRENT_PACKAGES_DIR}/share/unofficial-${PORT}/unofficial-${PORT}-config.cmake" @ONLY)
|
2019-07-16 07:33:11 +08:00
|
|
|
|
2023-11-17 08:49:36 +08:00
|
|
|
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE.txt")
|