Skip to content

Instantly share code, notes, and snippets.

@darcyliu
Last active April 3, 2016 22:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save darcyliu/9c26affb558e61758ffe to your computer and use it in GitHub Desktop.
Save darcyliu/9c26affb558e61758ffe to your computer and use it in GitHub Desktop.
Install OpenCV on OS X Yosemite
#!/bin/bash
# Install OpenCV on OS X Yosemite
# # install cmake
# curl -O https://cmake.org/files/v3.4/cmake-3.4.3.tar.gz
# tar xzvf cmake-3.4.3.tar.gz
# cd cmake-3.4.3
# ./bootstrap
# make
# make install
# cmake -version
# # install OpenCV 3.0.0
# curl -o opencv-3.0.0.zip https://codeload.github.com/Itseez/opencv/zip/2.4.11
# unzip opencv-3.0.0.zip
# cd opencv-3.0.0
# mkdir build
# cd build
# cmake -D PYTHON2_PACKAGES_PATH=/Library/Python/2.7/site-packages -G "Unix Makefiles" ..
# make
# make install
# install OpenCV 2.4.11
curl -o opencv-2.4.11.zip https://codeload.github.com/Itseez/opencv/zip/2.4.11
unzip opencv-2.4.11.zip
cd opencv-2.4.11
mkdir build
cd build
cmake -D PYTHON_PACKAGES_PATH=/Library/Python/2.7/site-packages \
-D INSTALL_PYTHON_EXAMPLES=ON \
-D INSTALL_C_EXAMPLES=ON \
-D BUILD_EXAMPLES=ON \
-G "Unix Makefiles" ..
make
make install
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment