How Do You Install opencv / cv2 without pip3 so The -DWITH_FFMPEG=ON is Set On?

Problem scenario
You do not want to use pip or pip3 to install opencv. How do you install opencv (with the -DWITH_FFMPEG=ON flag)?

This assumes that cmake has been installed. If you are running Ubuntu/Debian, run this: sudo apt -y install cmake
If you are running CentOS/RHEL/Fedora (some RedHat derivative), run this: sudo yum -y install cmake
If you are running SUSE, run this: sudo zypper -n install cmake


Run these commands:

wget -O

sudo cp -i /bin/
cd /bin
sudo unzip /bin/
sudo mkdir build && cd build
sudo cmake ../opencv-master -DWITH_FFMPEG=ON

Leave a comment

Your email address will not be published. Required fields are marked *