vcpkg/ports/magic-enum/portfile.cmake
Daniil Goncharov c567729cbc
[magic-enum] Update to v0.8.1 (#26166)
* [magic-enum] Update to v0.8.1

* vcpkg x-add-version magic-enum
2022-08-05 23:47:19 -07:00

28 lines
854 B
CMake

# header-only library
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO Neargye/magic_enum
REF v0.8.1
SHA512 97b14ddfa2fec4b582f4658cea96f61510b3eb1f367d770a642136ffbaf7e5d87e6a8c950f7ac6af47cc605899d0ff8e2b9c71a19a28ad1dfaa724f003339edc
HEAD_REF master
)
vcpkg_cmake_configure(
SOURCE_PATH "${SOURCE_PATH}"
OPTIONS
-DMAGIC_ENUM_OPT_ENABLE_NONASCII=OFF
-DMAGIC_ENUM_OPT_BUILD_EXAMPLES=OFF
-DMAGIC_ENUM_OPT_BUILD_TESTS=OFF
-DMAGIC_ENUM_OPT_INSTALL=ON
)
vcpkg_cmake_install()
vcpkg_cmake_config_fixup(CONFIG_PATH lib/cmake/magic_enum PACKAGE_NAME magic_enum)
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug" "${CURRENT_PACKAGES_DIR}/lib")
# Handle copyright
configure_file("${SOURCE_PATH}/LICENSE" "${CURRENT_PACKAGES_DIR}/share/${PORT}/copyright" COPYONLY)