vcpkg/ports/liblsl/portfile.cmake
chausner a1b1c72016
[liblsl] Update to 1.16.1 (#29637)
* Update liblsl to 1.16.1

* Update CI baseline

---------

Co-authored-by: chausner <chausner@users.noreply.github.com>
2023-02-14 09:38:09 -08:00

33 lines
1.2 KiB
CMake

vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO sccn/liblsl
REF v${VERSION}
SHA512 d3af9be687c11272f0122585c8ba48c5d7482af6e6f0cecf640e674682da319246b490b536a890407c7511fcc07a59749ed43134bf7683d30304ac4e3989a73c
HEAD_REF master
PATCHES
use-find-package-asio.patch
)
string(COMPARE EQUAL "${VCPKG_LIBRARY_LINKAGE}" "static" LSL_BUILD_STATIC)
vcpkg_cmake_configure(
SOURCE_PATH "${SOURCE_PATH}"
OPTIONS
-DLSL_BUILD_STATIC=${LSL_BUILD_STATIC}
-DLSL_BUNDLED_BOOST=OFF # we use the boost vcpkg packages instead
-DLSL_BUNDLED_PUGIXML=OFF # we use the pugixml vcpkg package instead
-Dlslgitrevision=v${VERSION}
-Dlslgitbranch=master
)
vcpkg_cmake_install()
vcpkg_copy_pdbs()
vcpkg_copy_tools(TOOL_NAMES lslver AUTO_CLEAN)
vcpkg_cmake_config_fixup(PACKAGE_NAME LSL CONFIG_PATH lib/cmake/LSL)
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")
file(INSTALL "${SOURCE_PATH}/README.md" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}")
file(INSTALL "${SOURCE_PATH}/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)