Result with `export CPPFLAGS="-I/usr/include/ffmpeg -I$HOME/Downloads/git/opencv-2.4.13.6/include -I$HOME/Downloads/git/opencv-2.4.13.6/modules/ocl/include"`:
https://pastebin.com/pF1tdEkB
(I tried to remove `-I/usr/include/ffmpeg` from CPPFLAGS [to avoid later version of h* files] but still got:
https://pastebin.com/6nEBG3qd
--that file [libavcodec/avcodec.h] is in ffmpeg, and including ffmpeg with -I makes the first pastebin error)
OpenCV is on 3.4.1 on Fedora, so I tried the last 2.x tarball of opencv. OpenCV builds successfully, but butterflow does not:
mkdir -p ~/Downloads/git/ cd ~/Downloads/git/ wget https://github.com/opencv/opencv/archive/2.4.13.6.tar.gz tar xf 2.4.13.6.tar.gz
but it still doesn't have ocl (except in modules dir) so:
cd $USER/Downloads/git/opencv-2.4.13.6 mkdir build cd build
add -DOPENCV_GENERATE_PKGCONFIG=ON for "projects that use OpenCV" "not using CMake" (see https://docs.opencv.org/trunk/d7/d9f/tutorial_linux_install.html)
building opencv2 works, but may not be necessary:
cmake -D CMAKE_BUILD_TYPE=Release -DOPENCV_GENERATE_PKGCONFIG=ON -D CMAKE_INSTALL_PREFIX=/usr/local .. make -j$(nproc)
sudo make install # I didn't try installing opencv2
export CPPFLAGS="-I$HOME/Downloads/git/opencv-2.4.13.6/include -I$HOME/Downloads/git/opencv-2.4.13.6/modules/ocl/include" pip2 install https://github.com/dthpham/butterflow/archive/master.zip