[dv-processing] Update to latest version (#25992)

* [dv-processing] version update to 1.5

* [dv-processing] version update

* Removing port version

* Version bump

Co-authored-by: Rokas Jurevicius <rokas.jurevicius@inivation.com>
This commit is contained in:
jureviciusr 2022-08-01 18:58:22 +02:00 committed by GitHub
parent cf5979b735
commit 21feabf8fe
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 12 additions and 93 deletions

View File

@ -2,11 +2,9 @@ vcpkg_from_gitlab(
GITLAB_URL https://gitlab.com/inivation
OUT_SOURCE_PATH SOURCE_PATH
REPO dv/dv-processing
REF rel_1.4
SHA512 c011ca0e6d9842913ff35b0a03f9053bfbc98c090b6936e01f6514b8a35d31ee6d0a821f491be96400113e93967aa2d3e8ab19e558f5c3e9f8eba9ad4e1fe013
HEAD_REF d4ffab46a2849372789c5a2084821011165086ab
PATCHES
vcpkg-build.patch
REF 96d082a862bb1e5bfdc79b39aa09e7a50c2dac49
SHA512 cf74e8a6f94f690e159778b59eb2e4d9c8f51f09437e94a507a2ec8f42e167fe6d1413ba91ab608624a02b4b479b27f454e7b7792d125ce5a163f4aa98e774cc
HEAD_REF rel_1.5
)
vcpkg_from_gitlab(
@ -27,6 +25,7 @@ vcpkg_cmake_configure(
-DENABLE_TESTS=OFF
-DENABLE_SAMPLES=OFF
-DENABLE_PYTHON=OFF
-DENABLE_UTILITIES=OFF
-DBUILD_CONFIG_VCPKG=ON
)

View File

@ -1,84 +0,0 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index c7775b5..acf6208 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -27,11 +27,15 @@ IF(Git_FOUND AND EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/.git")
ENDIF()
ENDIF()
+OPTION(BUILD_CONFIG_VCPKG "Set build environment compatible with VCPKG" OFF)
+
# Basic setup, useful variables, see docs.
SET(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmakemod ${CMAKE_MODULE_PATH})
SET(ENABLE_ALL_WARNINGS ON CACHE BOOL "Turn on all warnings for build" FORCE)
INCLUDE(inivation-setup)
+# Skip compiler compatibility checks when doing the VCPKG build
+if(NOT BUILD_CONFIG_VCPKG)
# Compiler compatibility testing starts GCC has to be at least version 10
IF(CC_GCC AND ${CMAKE_CXX_COMPILER_VERSION} VERSION_LESS "10.0.0")
MESSAGE(
@@ -56,6 +60,7 @@ IF(NOT CC_GCC AND NOT CC_GCC)
)
ENDIF()
# Compiler compatibility testing ends
+ENDIF()
# Boost support. Search in extra directory for custom version.
IF(EXISTS /opt/inivation/boost/)
@@ -87,7 +92,7 @@ CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/${PROJECT_NAME}.pc.in ${CMAKE_CURRENT
INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}.pc DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig)
# Cmake find_package() support.
-IF(CC_MSVC)
+IF(BUILD_CONFIG_VCPKG)
SET(CMAKE_EXPORT_DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/${PROJECT_NAME})
ELSE()
SET(CMAKE_EXPORT_DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME})
@@ -103,8 +108,13 @@ INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}-config.cmake
${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}-config-version.cmake
${CMAKE_CURRENT_SOURCE_DIR}/cmakemod/inivation-setup.cmake DESTINATION ${CMAKE_EXPORT_DESTINATION})
-# External libraries to build
-ADD_SUBDIRECTORY(tests/external/cli11)
+IF (BUILD_CONFIG_VCPKG)
+ # Find CLI11 as an installed package
+ FIND_PACKAGE(CLI11 CONFIG REQUIRED)
+ELSE()
+ # External CLI11 checked-out as a submodule
+ ADD_SUBDIRECTORY(tests/external/cli11)
+ENDIF()
# Install header files.
ADD_SUBDIRECTORY(include)
diff --git a/dv-processing-config.cmake.in b/dv-processing-config.cmake.in
index 4dbf635..5557dd2 100644
--- a/dv-processing-config.cmake.in
+++ b/dv-processing-config.cmake.in
@@ -53,10 +53,9 @@ CHECK_REQUIRED_COMPONENTS(dv-processing)
# properly.
INCLUDE(@PACKAGE_CMAKE_EXPORT_DESTINATION@/inivation-setup.cmake)
-# MSVC/VCPKG finds this differently.
-IF(CC_MSVC)
- FIND_PACKAGE(lz4 CONFIG REQUIRED)
-ENDIF()
+# MSVC/VCPKG finds this differently, try to find it quietly, so it does not complain on non-vcpkg installations
+# and find the package correctly when used with VCPKG.
+FIND_PACKAGE(lz4 CONFIG QUIET)
# Compiler compatibility testing starts GCC has to be at least version 10
IF(CC_GCC AND ${CMAKE_CXX_COMPILER_VERSION} VERSION_LESS "10.0.0")
diff --git a/include/dv-processing/CMakeLists.txt b/include/dv-processing/CMakeLists.txt
index b83f4e4..621b3f2 100644
--- a/include/dv-processing/CMakeLists.txt
+++ b/include/dv-processing/CMakeLists.txt
@@ -23,7 +23,7 @@ IF(CC_MSVC)
ENDIF()
# Compression support
-IF(CC_MSVC)
+IF(BUILD_CONFIG_VCPKG)
FIND_PACKAGE(lz4 CONFIG REQUIRED)
TARGET_LINK_LIBRARIES(processing INTERFACE lz4::lz4)
ELSE()

View File

@ -1,7 +1,6 @@
{
"name": "dv-processing",
"version": "1.4.0",
"port-version": 1,
"version": "1.5.0",
"description": "Generic algorithms for event cameras.",
"homepage": "https://gitlab.com/inivation/dv/dv-processing",
"license": "Apache-2.0",

View File

@ -2009,8 +2009,8 @@
"port-version": 2
},
"dv-processing": {
"baseline": "1.4.0",
"port-version": 1
"baseline": "1.5.0",
"port-version": 0
},
"dx": {
"baseline": "1.0.1",

View File

@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "e45cf567d2617df07999f47cff84636f513a0c1c",
"version": "1.5.0",
"port-version": 0
},
{
"git-tree": "d46e8c68fbd834385ac3fa859b35e72cb5bc8648",
"version": "1.4.0",