Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Building Python Bindings on Jetson Xavier Ubuntu 20.04 Arm64 #11634

Closed
bhomaidan1990 opened this issue Mar 30, 2023 · 2 comments
Closed

Building Python Bindings on Jetson Xavier Ubuntu 20.04 Arm64 #11634

bhomaidan1990 opened this issue Mar 30, 2023 · 2 comments

Comments

@bhomaidan1990
Copy link

bhomaidan1990 commented Mar 30, 2023


Required Info
Operating System & Version Ubuntu 20.04
Kernel Version (Linux Only) 5.10.104-tegra
Platform NVIDIA Jetson Xavier NX dev-kit
SDK Version 2.50.0
CMake Version 3.26.1

Issue Description

I want to build librealsense 2.50.0 with python bindings from source on Jetson Xavier NX dev-kit, I have done:

~/Downloads/librealsense-2.50.0/build$ cmake ../ -DFORCE_LIBUVC=true\
-DCMAKE_BUILD_TYPE=release \
-DBUILD_WITH_CUDA=true -DBUILD_PYTHON_BINDINGS=true\
-DBUILD_NODEJS_BINDINGS=true -DPYTHON_EXECUTABLE=/usr/bin/python3\
-DBUILD_EXAMPLES=true -DBUILD_GRAPHICAL_EXAMPLES=true\
-DPYTHON_INCLUDE_DIR=/usr/include/python3.8 \
-DPYTHON_LIBRARY=/usr/lib/libpython3.8.so

I get the output:

-- Checking internet connection...
-- Internet connection identified
CMake Deprecation Warning at CMakeLists.txt:9 (MESSAGE):
  FORCE_LIBUVC, FORCE_WINUSB_UVC and ANDROID_USB_HOST_UVC are deprecated, use
  FORCE_RSUSB_BACKEND instead


-- Info: REALSENSE_VERSION_STRING=2.50.0
-- Setting Unix configurations
-- Info: Building with CUDA requires CMake v3.8+
-- CUDA_LIBRARIES: /usr/local/cuda-11.4/include /usr/local/cuda-11.4/lib64/libcudart_static.a;Threads::Threads;dl;/usr/lib/aarch64-linux-gnu/librt.so;/usr/local/cuda-11.4/lib64/libcusparse.so;/usr/local/cuda-11.4/lib64/libcublas.so
-- Building libcurl enabled
-- using RS2_USE_LIBUVC_BACKEND
-- Configuring done (0.1s)
-- Generating done (0.0s)
-- Build files have been written to: /home/marvin/Downloads/librealsense-2.50.0/build/external-projects/pybind11
[ 12%] Performing update step for 'pybind11'
[ 25%] No patch step for 'pybind11'
[ 37%] No configure step for 'pybind11'
[ 50%] No build step for 'pybind11'
[ 62%] No install step for 'pybind11'
[ 75%] Completed 'pybind11'
[100%] Built target pybind11
-- pybind11 v2.6.2

Then I get an error:

CMake Error at /usr/share/cmake-3.26/Modules/FindPackageHandleStandardArgs.cmake:230 (message):
  Could NOT find Python (missing: Python_INCLUDE_DIRS Development
  Development.Module Development.Embed) (found version "2.7.18")
Call Stack (most recent call first):
  /usr/share/cmake-3.26/Modules/FindPackageHandleStandardArgs.cmake:600 
(_FPHSA_FAILURE_MESSAGE)
  /usr/share/cmake-3.26/Modules/FindPython.cmake:622 
(find_package_handle_standard_args)
  wrappers/python/CMakeLists.txt:63 (find_package)

I have solved this error before by removing the Development directory from the cmake find python, can you please tell me how can I solve this problem properly? thanks in advance.

@MartyG-RealSense
Copy link
Collaborator

Hi @bhomaidan1990 There is a guide at #6964 (comment) for installing librealsense and the Python wrapper at the same time from source code on Jetson boards. References to Python 3.6 in the instructions should be changed to the Python 3.8 version that you are using.

@MartyG-RealSense
Copy link
Collaborator

Hi @bhomaidan1990 Do you require further assistance with this case, please? Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants