vcpkg/ports/unicorn-lib/portfile.cmake

31 lines
923 B
CMake
Raw Normal View History

include(vcpkg_common_functions)
if (VCPKG_LIBRARY_LINKAGE STREQUAL dynamic)
message("unicorn-lib is a static library, now build with static.")
set(VCPKG_LIBRARY_LINKAGE static)
endif()
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO CaptainCrowbar/unicorn-lib
REF ba11f5930dbeb5f8e04b2ee727b6dd3932fd6b03
SHA512 2b1c8f12c3d29bfcff7209763000f2b9db612cefd384d9f015cc07a1ebeb498ba3e8b13dba4d94a86828d3f7eafc17eede21be9926080426f0417d3ad2cee396
HEAD_REF master
)
file(COPY ${CURRENT_PORT_DIR}/CMakeLists.txt DESTINATION ${SOURCE_PATH})
vcpkg_configure_cmake(
SOURCE_PATH ${SOURCE_PATH}
PREFER_NINJA
2018-02-26 03:37:23 +08:00
OPTIONS_DEBUG
-DUNICORN_LIB_SKIP_HEADERS=ON
)
vcpkg_install_cmake()
vcpkg_copy_pdbs()
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share)
# Handle copyright
2019-06-02 08:04:47 +08:00
file(INSTALL ${SOURCE_PATH}/LICENSE.txt DESTINATION ${CURRENT_PACKAGES_DIR}/share/unicorn-lib RENAME copyright)