diff options
| author | Ethan Morgan <ethan@gweithio.com> | 2026-02-14 16:44:06 +0000 |
|---|---|---|
| committer | Ethan Morgan <ethan@gweithio.com> | 2026-02-14 16:44:06 +0000 |
| commit | 54409423f767d8b1cf30cb7d0efca6b4ca138823 (patch) | |
| tree | d915ac7828703ce4b963efdd9728a1777ba18c1e /vcpkg/ports/libcaer | |
Diffstat (limited to 'vcpkg/ports/libcaer')
| -rw-r--r-- | vcpkg/ports/libcaer/portfile.cmake | 37 | ||||
| -rw-r--r-- | vcpkg/ports/libcaer/vcpkg.json | 39 |
2 files changed, 76 insertions, 0 deletions
diff --git a/vcpkg/ports/libcaer/portfile.cmake b/vcpkg/ports/libcaer/portfile.cmake new file mode 100644 index 0000000..f5aa172 --- /dev/null +++ b/vcpkg/ports/libcaer/portfile.cmake @@ -0,0 +1,37 @@ +vcpkg_from_gitlab(
+ GITLAB_URL https://gitlab.com/inivation/
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO dv/libcaer
+ REF "${VERSION}"
+ SHA512 651e7e92730be6e10e1efab9c11a111e99b338a29239a79d61169c8130c4149eda99a624205db36c4a21da023ff1525f31c4175947f72c78bc2a8b40c9d2c2ab
+ HEAD_REF master
+)
+
+find_program(PKGCONFIG NAMES pkgconf PATHS "${CURRENT_HOST_INSTALLED_DIR}/tools/pkgconf" NO_DEFAULT_PATH REQUIRED)
+
+vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
+ FEATURES
+ opencv ENABLE_OPENCV
+)
+
+vcpkg_cmake_configure(
+ SOURCE_PATH "${SOURCE_PATH}"
+ DISABLE_PARALLEL_CONFIGURE # writes to include/libcaer/libcaer.h
+ OPTIONS
+ ${FEATURE_OPTIONS}
+ -DEXAMPLES_INSTALL=OFF
+ -DBUILD_CONFIG_VCPKG=ON
+ "-DPKG_CONFIG_EXECUTABLE=${PKGCONFIG}"
+)
+
+vcpkg_cmake_install()
+
+vcpkg_fixup_pkgconfig()
+vcpkg_cmake_config_fixup()
+
+file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")
+file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
+
+set(stdatomic_license "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-rel/LICENSE for simple-stdatomic (x86,x64 MSVC)")
+file(COPY_FILE "${SOURCE_PATH}/thirdparty/simple-stdatomic/LICENSE" "${stdatomic_license}")
+vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE" "${stdatomic_license}")
diff --git a/vcpkg/ports/libcaer/vcpkg.json b/vcpkg/ports/libcaer/vcpkg.json new file mode 100644 index 0000000..29b1951 --- /dev/null +++ b/vcpkg/ports/libcaer/vcpkg.json @@ -0,0 +1,39 @@ +{ + "name": "libcaer", + "version": "3.3.17", + "description": "Minimal C library to access, configure and get data from neuromorphic sensors and processors.", + "homepage": "https://gitlab.com/inivation/dv/libcaer", + "license": "BSD-2-Clause AND Apache-2.0", + "supports": "!(arm & windows & !mingw)", + "dependencies": [ + "libusb", + { + "name": "pkgconf", + "host": true + }, + { + "name": "vcpkg-cmake", + "host": true + }, + { + "name": "vcpkg-cmake-config", + "host": true + } + ], + "features": { + "opencv": { + "description": "Enable support for frame enhancements using OpenCV", + "dependencies": [ + { + "name": "opencv4", + "default-features": false, + "features": [ + "fs", + "intrinsics", + "thread" + ] + } + ] + } + } +} |