Every time we install OpenCV on a new computer it is almost the same ritual…


     Download, organize folders, get the required dependencies… Newcomers feel overwhelmed by the steps required to use the C++ version. I think is because of that fact that the 3 most accessed tutorials here on my blog are OpenCV compilation tutorials.

 

The solution is an automation script!

     I decided to code a bash script to automate the steps required to get the latest OpenCV version running on a Linux PC. It functions by doing the following steps:

 

  • Create a clean ~/opencv folder;
  • Download all required dependencies and OpenCV & Contrib tars;
  • Extract and make them.

 

The script is available here. The entire project including a simple test is on my Github: https://github.com/Jeanvit/opencvautoinstaller.

 

     Each time a new OpenCV version becomes available, I’ll make sure to update the script. Also, feel free to contribute by opening a pull request, commenting here, or just mailing me! Remember, it’s to make things better for all of us!

 

 

 

 

Have fun with your projects! 
If this post helped you, please consider buying me a coffee 🙂