Created
June 16, 2022 14:06
-
-
Save Flojomojo/658fc691ff55d0217e51a69e31ec98a3 to your computer and use it in GitHub Desktop.
build script for opencv using a custom ffmpeg installation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # Note: You need to replace the path accordingly | |
| export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/insert/path/here/ffmpeg-4.4.1-5/lib | |
| export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/insert/path/here/ffmpeg-4.4.1-5/lib/pkgconfig | |
| export PKG_CONFIG_LIBDIR=$PKG_CONFIG_LIBDIR:/insert/path/here/ffmpeg-4.4.1-5/lib | |
| cmake \ | |
| -D BUILD_EXAMPLES=ON \ | |
| -D BUILD_TESTS=OFF \ | |
| -D OPENCV_EXTRA_EXE_LINKER_FLAGS="-Wl,-rpath,/insert/path/here/ffmpeg-4.4.1-5/lib" \ | |
| -D CMAKE_BUILD_TYPE=RELEASE \ | |
| -D CMAKE_INSTALL_PREFIX=$HOME/Applications/opencv \ | |
| /insert/path/here/opencv-python/opencv |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment