cmake gets confused and thinks that build directory is source directory

Viewed 40

I am trying to install opencv on my raspberry pi 4 with raspian OS.

I am using this tutorial https://docs.opencv.org/3.4/d7/d9f/tutorial_linux_install.html and I have navigated to a build directory in my source directory /home/icetea/Desktop/working_dir/opencv/build

Then I execute this command:

cmake -D CMAKE_BUILD_TYPE=Release -D CMAKE_INSTALL_PREFIX=/home/icetea/Desktop/working_dir/opencv

I get this error:

CMake Error: The source directory "/home/icetea/Desktop/working_dir/opencv/build" does not appear to contain CMakeLists.txt

It thinks the build dir is the source dir. My source dir does 100% contain that .txt file, but my build dir is empty. I have tried executing this command while in the source dir and I get this error:

FATAL: In-source builds are not allowed. You should create a separate directory for build files

Anybody have any insight?

Thank you very much

Smitty

0 Answers
Related