Librealsense2 android build (#15608)

* [realsense2] options for android build

* bump port version

* update baseline

Co-authored-by: JackBoosY <yuzaiyang@beyondsoft.com>
This commit is contained in:
Ilya Arzhannikov 2021-01-20 00:28:30 +01:00 committed by GitHub
parent ab077c4e55
commit 2f542209ce
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 13 additions and 1 deletions

View File

@ -4998,7 +4998,7 @@
},
"realsense2": {
"baseline": "2.40.0",
"port-version": 0
"port-version": 1
},
"recast": {
"baseline": "1.5.1-3",

View File

@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "7a17b91ddec89be9345ca08ba098ffec3ee4618d",
"version-string": "2.40.0",
"port-version": 1
},
{
"git-tree": "c3d32b35fd3a11aec9bd32f3f458ea4b099816f7",
"version-string": "2.40.0",

View File

@ -1,5 +1,6 @@
Source: realsense2
Version: 2.40.0
Port-Version: 1
Homepage: https://github.com/IntelRealSense/librealsense
Description: Intel® RealSense™ SDK 2.0 is a cross-platform library for Intel® RealSense™ depth cameras (D400 series and the SR300).
Build-Depends: libusb(linux)

View File

@ -26,6 +26,11 @@ if(("openni2" IN_LIST FEATURES) AND (VCPKG_LIBRARY_LINKAGE STREQUAL "dynamic"))
set(BUILD_OPENNI2_BINDINGS ON)
endif()
set(PLATFORM_OPTIONS)
if (VCPKG_TARGET_IS_ANDROID)
list(APPEND PLATFORM_OPTIONS -DFORCE_RSUSB_BACKEND=ON)
endif()
vcpkg_configure_cmake(
SOURCE_PATH ${SOURCE_PATH}
PREFER_NINJA
@ -36,6 +41,7 @@ vcpkg_configure_cmake(
-DBUILD_WITH_STATIC_CRT=${BUILD_CRT_LINKAGE}
-DBUILD_OPENNI2_BINDINGS=${BUILD_OPENNI2_BINDINGS}
-DOPENNI2_DIR=${CURRENT_INSTALLED_DIR}/include/openni2
${PLATFORM_OPTIONS}
OPTIONS_RELEASE
-DBUILD_EXAMPLES=${BUILD_TOOLS}
-DBUILD_GRAPHICAL_EXAMPLES=${BUILD_TOOLS}