vcpkg/ports/discordcoreapi/portfile.cmake
2023-11-28 21:52:21 -08:00

28 lines
840 B
CMake

if(VCPKG_TARGET_IS_LINUX)
message(WARNING "DiscordCoreAPI only supports g++ 11 on linux.")
endif()
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO RealTimeChris/DiscordCoreAPI
REF "v${VERSION}"
SHA512 12302c6ef374ee7e88538c4f736642ab15b6455f3db08ffd2028a84c843c0c13300f3ee300f5e12d3c7621fa9f914d3ceb29da52587ed678f6d0ce41c3d9e0d5
HEAD_REF main
)
vcpkg_cmake_configure(
SOURCE_PATH "${SOURCE_PATH}"
)
vcpkg_cmake_install()
vcpkg_cmake_config_fixup(NO_PREFIX_CORRECTION)
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include" "${CURRENT_PACKAGES_DIR}/debug/share")
if(VCPKG_LIBRARY_LINKAGE STREQUAL "static")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/bin" "${CURRENT_PACKAGES_DIR}/debug/bin")
endif()
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/License.md")