Ask Your Question

Revision history [back]

OpenCV fails to install on Jetson Nano

I am attempting to install OpenCV on my Jetson Nano following the "Get Your Jestson Nano Working" instructions in the Donkey Car instructions and when I complete the Cmake Setup instructions:

Create a build directory

cd projects/cv2/opencv

mkdir build

cd build

Setup CMake

cmake -D CMAKE_BUILD_TYPE=RELEASE \

-D CMAKE_INSTALL_PREFIX=/usr/local \

-D INSTALL_PYTHON_EXAMPLES=ON \

-D INSTALL_C_EXAMPLES=OFF \

-D OPENCV_ENABLE_NONFREE=ON \

# Contrib path
-D OPENCV_EXTRA_MODULES_PATH=~/projects/cv2/opencv_contrib/modules \

# Your virtual environment's Python executable
# You need to specify the result of echo $(which python)
-D PYTHON_EXECUTABLE=~/env/bin/python \

-D BUILD_EXAMPLES=ON ../opencv

I get a message saying "CMake Error: The source directory "/home/donkey/projects/cv2/opencv/opencv" does not exist.

Of course it does not exist because "projects/cv2/opencv/" is in the "home" directory and there is no "donkey" directory in the "home" directory. Can anyone tell me what in the Cmake Setup instructions are causing "donkey" directory and the additional "/opencv" to be inserted in the installation path? I suspect that the Cmake Setup "-D CMAKE_INSTALL_PREFIX=/usr/local \" might be causing the problem. Also "-D OPENCV_EXTRA_MODULES_PATH=~/projects/cv2/opencv_contrib/modules \" does not result in an error. Regards, TCIII

click to hide/show revision 2
None

updated 2019-11-03 09:49:54 -0600

berak gravatar image

OpenCV fails to install on Jetson Nano

I am attempting to install OpenCV on my Jetson Nano following the "Get Your Jestson Nano Working" instructions in the Donkey Car instructions and when I complete the Cmake Setup instructions:

# Create a build directory

directory cd projects/cv2/opencv

projects/cv2/opencv mkdir build

build cd build

Setup CMake

build # Setup CMake cmake -D CMAKE_BUILD_TYPE=RELEASE \

\

    -D CMAKE_INSTALL_PREFIX=/usr/local \

 -D INSTALL_PYTHON_EXAMPLES=ON \

 -D INSTALL_C_EXAMPLES=OFF \

 -D OPENCV_ENABLE_NONFREE=ON \

 # Contrib path
 -D OPENCV_EXTRA_MODULES_PATH=~/projects/cv2/opencv_contrib/modules \

 # Your virtual environment's Python executable
 # You need to specify the result of echo $(which python)
 -D PYTHON_EXECUTABLE=~/env/bin/python \

 -D BUILD_EXAMPLES=ON ../opencv

I get a message saying "CMake Error: The source directory "/home/donkey/projects/cv2/opencv/opencv" does not exist.

Of course it does not exist because "projects/cv2/opencv/" is in the "home" directory and there is no "donkey" directory in the "home" directory. Can anyone tell me what in the Cmake Setup instructions are causing "donkey" directory and the additional "/opencv" to be inserted in the installation path? I suspect that the Cmake Setup "-D CMAKE_INSTALL_PREFIX=/usr/local \" might be causing the problem. Also "-D OPENCV_EXTRA_MODULES_PATH=~/projects/cv2/opencv_contrib/modules \" does not result in an error. Regards, TCIII

OpenCV fails to install on Jetson Nano

I am attempting to install OpenCV on my Jetson Nano following the "Get Your Jestson Nano Working" instructions in the Donkey Car instructions and when I complete the Cmake Setup instructions:

# Create a build directory
cd projects/cv2/opencv

mkdir build

cd build

# Setup CMake
cmake -D CMAKE_BUILD_TYPE=RELEASE \

    -D CMAKE_INSTALL_PREFIX=/usr/local \

    -D INSTALL_PYTHON_EXAMPLES=ON \

    -D INSTALL_C_EXAMPLES=OFF \

    -D OPENCV_ENABLE_NONFREE=ON \

    # Contrib path
    -D OPENCV_EXTRA_MODULES_PATH=~/projects/cv2/opencv_contrib/modules \

    # Your virtual environment's Python executable
    # You need to specify the result of echo $(which python)
    -D PYTHON_EXECUTABLE=~/env/bin/python \

    -D BUILD_EXAMPLES=ON ../opencv

I get a message saying "CMake Error: The source directory "/home/donkey/projects/cv2/opencv/opencv" does not exist.

Of course it does not exist because "projects/cv2/opencv/" is in the "home" directory and there is no "donkey" directory in the "home" directory. Can anyone tell me what in the Cmake Setup instructions are causing "donkey" directory and the additional "/opencv" to be inserted in the installation path? I suspect that the Cmake Setup "-D CMAKE_INSTALL_PREFIX=/usr/local \" might be causing the problem. Also "-D OPENCV_EXTRA_MODULES_PATH=~/projects/cv2/opencv_contrib/modules \" does not result in an error. Regards, TCIII