vcpkg/ports/discordcoreapi/portfile.cmake
2023-07-25 11:01:11 -07: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 158beeb5739ab69e5d2977c78030b24cada3e32a9b53ec0195a7b17b30c686ecd3fe29f5f11a530118312bd14db5b8d0ac0707e1675d0a3fc4da355ad66527dd
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")