mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-12-03 02:09:00 +08:00
4c366a7914
- [x] Changes comply with the [maintainer guide](https://github.com/microsoft/vcpkg-docs/blob/main/vcpkg/contributing/maintainer-guide.md). - [x] SHA512s are updated for each updated download. - [x] The "supports" clause reflects platforms that may be fixed by this new version. - [x] Any fixed [CI baseline](https://github.com/microsoft/vcpkg/blob/master/scripts/ci.baseline.txt) entries are removed from that file. - [x] Any patches that are no longer applied are deleted from the port's directory. - [x] The version database is fixed by rerunning `./vcpkg x-add-version --all` and committing the result. - [x] Only one version is added to each modified port's versions file. --------- Co-authored-by: Kai Pastor <dg0yt@darc.de>
35 lines
993 B
CMake
35 lines
993 B
CMake
vcpkg_from_github(
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
|
REPO libuvc/libuvc
|
|
REF "v${VERSION}"
|
|
SHA512 cf2c0a6cc04717f284f25bed17f178a4b2b2a2bb3e5937e50be144e88db2c481c5ea763c164fe0234834fea4837f96fcc13bdbdafd4610d2985943562dfcc72f
|
|
HEAD_REF master
|
|
PATCHES build_fix.patch
|
|
)
|
|
|
|
if (VCPKG_LIBRARY_LINKAGE STREQUAL "dynamic")
|
|
set(BUILD_TARGET "Shared")
|
|
else()
|
|
set(BUILD_TARGET "Static")
|
|
endif()
|
|
|
|
vcpkg_find_acquire_program(PKGCONFIG)
|
|
vcpkg_cmake_configure(
|
|
SOURCE_PATH ${SOURCE_PATH}
|
|
OPTIONS
|
|
-DPKG_CONFIG_EXECUTABLE="${PKGCONFIG}"
|
|
-DCMAKE_BUILD_TARGET=${BUILD_TARGET}
|
|
-DBUILD_EXAMPLE=OFF
|
|
-DBUILD_TEST=OFF
|
|
)
|
|
vcpkg_cmake_install()
|
|
|
|
vcpkg_cmake_config_fixup(CONFIG_PATH lib/cmake/${PORT})
|
|
vcpkg_fixup_pkgconfig()
|
|
|
|
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
|
|
|
|
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE.txt")
|
|
|
|
file(INSTALL "${CMAKE_CURRENT_LIST_DIR}/usage" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}")
|