vcpkg/ports/commsdsl/portfile.cmake
2020-11-23 16:17:05 -08:00

34 lines
1.0 KiB
CMake

vcpkg_fail_port_install(ON_TARGET "uwp")
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO commschamp/commsdsl
REF v3.5.4
SHA512 d2bbb5332606d86200645f628507da966b385c2d8f0010e8cb83e0cdb3f3384272021db24ccb9418c69b4bd61a38edc18149cd0f7adbbbbc30168d0a15abef58
HEAD_REF master
)
vcpkg_configure_cmake(
SOURCE_PATH ${SOURCE_PATH}
PREFER_NINJA
OPTIONS
-DCOMMSDSL_NO_COMMS_CHAMPION=ON
-DCOMMSDSL_NO_TESTS=ON
-DCOMMSDSL_NO_WARN_AS_ERR=ON # remove on next version or on next version of boost
)
vcpkg_install_cmake()
vcpkg_copy_tools(
TOOL_NAMES commsdsl2comms
SEARCH_DIR ${CURRENT_PACKAGES_DIR}/bin
AUTO_CLEAN
)
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
if(VCPKG_LIBRARY_LINKAGE STREQUAL "static")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/bin" "${CURRENT_PACKAGES_DIR}/debug/bin")
endif()
# Handle copyright
file(INSTALL ${SOURCE_PATH}/LICENSE.txt DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright)