mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-11-29 06:09:08 +08:00
32 lines
841 B
CMake
32 lines
841 B
CMake
# header-only library
|
|
|
|
include(vcpkg_common_functions)
|
|
|
|
vcpkg_from_github(
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
|
REPO Neargye/nameof
|
|
REF v0.9.2
|
|
SHA512 b83167daf13e1e4f174d723a8aaeb13cb386eb7bd5a74ebf4cdc34c78f5deb537c11d8b5204df26c827de11e10bd9006854c1f898e1fcf6526ad0e41aff6987b
|
|
HEAD_REF master
|
|
)
|
|
|
|
vcpkg_configure_cmake(
|
|
SOURCE_PATH ${SOURCE_PATH}
|
|
PREFER_NINJA
|
|
OPTIONS
|
|
-DNAMEOF_OPT_BUILD_EXAMPLES=OFF
|
|
-DNAMEOF_OPT_BUILD_TESTS=OFF
|
|
)
|
|
|
|
vcpkg_install_cmake()
|
|
|
|
vcpkg_fixup_cmake_targets(CONFIG_PATH lib/cmake/nameof)
|
|
|
|
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug ${CURRENT_PACKAGES_DIR}/lib)
|
|
|
|
# Handle copyright
|
|
configure_file(${SOURCE_PATH}/LICENSE ${CURRENT_PACKAGES_DIR}/share/nameof/copyright COPYONLY)
|
|
|
|
# CMake integration test
|
|
vcpkg_test_cmake(PACKAGE_NAME nameof)
|