Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # use `which python3` to get PYTHON3_EXECUTABLE
- # use `python3-config --includes` to get PYTHON3_INCLUDE_DIR and PYTHON3_INCLUDE_DIR2
- # use `python3-config --ldflags` and `python3-config --configdir` to get PYTHON_LIBRARY
- # go to side-packages folder to get PYTHON3_NUMPY_INCLUDE_DIRS
- # static libraries build
- cmake \
- -D CMAKE_BUILD_TYPE=Release \
- -D BUILD_SHARED_LIBS=OFF \
- -D CMAKE_INSTALL_PREFIX=/Users/ling/Packages/opencv \
- -D PYTHON3_EXECUTABLE=/Users/ling/opencv_venv/bin/python3 \
- -D PYTHON3_INCLUDE_DIR=/Users/ling/homebrew/Cellar/python/3.6.5_1/Frameworks/Python.framework/Versions/3.6/include/python3.6m \
- -D PYTHON3_INCLUDE_DIR2=/Users/ling/homebrew/Cellar/python/3.6.5_1/Frameworks/Python.framework/Versions/3.6/include/python3.6m \
- -D PYTHON3_LIBRARY=/Users/ling/homebrew/opt/python/Frameworks/Python.framework/Versions/3.6/lib/python3.6/config-3.6m-darwin/libpython3.6m.a \
- -D PYTHON3_NUMPY_INCLUDE_DIRS=/Users/ling/opencv_venv/lib/python3.6/site-packages/numpy/core/include \
- ..
- # dynasty libraries build
- cmake \
- -D CMAKE_BUILD_TYPE=Release \
- -D CMAKE_INSTALL_RPATH="@loader_path" \
- -D CMAKE_INSTALL_PREFIX=/Users/ling/Packages/opencv \
- -D PYTHON3_EXECUTABLE=/Users/ling/opencv_venv/bin/python3 \
- -D PYTHON3_INCLUDE_DIR=/Users/ling/homebrew/Cellar/python/3.6.5_1/Frameworks/Python.framework/Versions/3.6/include/python3.6m \
- -D PYTHON3_INCLUDE_DIR2=/Users/ling/homebrew/Cellar/python/3.6.5_1/Frameworks/Python.framework/Versions/3.6/include/python3.6m \
- -D PYTHON3_LIBRARY=/Users/ling/homebrew/opt/python/Frameworks/Python.framework/Versions/3.6/lib/python3.6/config-3.6m-darwin/libpython3.6m.dylib \
- -D PYTHON3_NUMPY_INCLUDE_DIRS=/Users/ling/opencv_venv/lib/python3.6/site-packages/numpy/core/include \
- ..
Add Comment
Please, Sign In to add comment