I did the following on my Raspberry Pi:
cd ~
wget -O opencv.zip https://github.com/Itseez/opencv/archive/3.1.0.zip
wget -O opencv_contrib.zip https://github.com/Itseez/opencv_contrib/archive/3.1.0.zip
cd ~/opencv-3.1.0/
mkdir build
cd build
cmake -D CMAKE_BUILD_TYPE=RELEASE -D CMAKE_INSTALL_PREFIX=/usr/local -D INSTALL_PYTHON_EXAMPLES=ON -D OPENCV_EXTRA_MODULES_PATH=~/opencv/contrib-3.1.0/modules -D BUILD_EXAMPLES=ON ..
make -j4
The make -j4
returns make: *** No targets specified and no makefile found. Stop.
I checked that make is installed on my device with make --version
and found I have version 4.0. I also tried running the likes of /usr/bin/make -j4
but continue to get the same error.
From what I've found online I think I should expect a makefile or Makefile to be in my directory but none exists.
What am I doing wrong and how do I resolve this?
Additional Information
I keep seeing references to a ./configuration file but I don't have this file.
I'm not sure what went wrong when I worked through the steps outlined in my question. I didn't see any errors.
However, I deleted the build folder and ran through the following again:
mkdir build
cd build
cmake -D CMAKE_BUILD_TYPE=RELEASE -D CMAKE_INSTALL_PREFIX=/usr/local -D INSTALL_PYTHON_EXAMPLES=ON -D OPENCV_EXTRA_MODULES_PATH=~/opencv/contrib-3.1.0/modules -D BUILD_EXAMPLES=ON ..
make -j4
This time I noticed a lot more files, including Makefile. Now when I run make -j4
it runs without error.