Skip to content

Instantly share code, notes, and snippets.

@curtkim
Last active August 7, 2019 05:56
Show Gist options
  • Save curtkim/e83954228b5b17c914dfb1a5158728d7 to your computer and use it in GitHub Desktop.
Save curtkim/e83954228b5b17c914dfb1a5158728d7 to your computer and use it in GitHub Desktop.
openMVS dockerfile
FROM ubuntu:16.04
#Prepare and empty machine for building:
RUN apt-get update -qq && apt-get install -qq
RUN apt-get -y install build-essential \
git \
mercurial \
cmake \
libpng-dev \
libjpeg-dev \
libtiff-dev \
libglu1-mesa-dev \
libxmu-dev \
libxi-dev
#Boost (Required)
RUN apt-get -y install libboost-iostreams-dev libboost-program-options-dev libboost-system-dev libboost-serialization-dev
#OpenCV (Required)
RUN apt-get -y install libopencv-dev
#CGAL (Required)
RUN apt-get -y install libcgal-dev libcgal-qt5-dev
#Eigen
RUN git clone --branch 3.2.0 https://github.com/eigenteam/eigen-git-mirror.git eigen && \
mkdir eigen_build && \
cd eigen_build && \
cmake . ../eigen && \
make && \
make install && \
cd ..
#Ceres (Required)
RUN apt-get -y install libatlas-base-dev libsuitesparse-dev
RUN git clone https://ceres-solver.googlesource.com/ceres-solver ceres-solver && \
mkdir ceres_build && \
cd ceres_build && \
cmake . ../ceres-solver/ -DMINIGLOG=ON -DBUILD_TESTING=OFF -DBUILD_EXAMPLES=OFF && \
make -j2 && \
make install && \
cd ..
#GLFW3 (Optional)
RUN apt-get -y install freeglut3-dev libglew-dev libglfw3-dev
#VCGLib (Required)
RUN git clone https://github.com/cdcseacave/VCG.git vcglib
ADD . /opt/openMVS
RUN cd /opt && \
mkdir openMVS_build && \
cd openMVS_build && \
cmake . ../openMVS -DCMAKE_BUILD_TYPE=Release -DVCG_ROOT="/vcglib" && \
make -j2 && \
make install
# openMVG
RUN apt-get install libpng-dev \
libjpeg-dev \
libtiff-dev \
libxxf86vm1 \
libxxf86vm-dev \
libxi-dev \
libxrandr-dev
RUN git clone --recursive https://github.com/openMVG/openMVG.git && \
mkdir openMVG_Build && \
cd openMVG_Build && \
cmake -DCMAKE_BUILD_TYPE=RELEASE ../openMVG/src/ && \
cmake --build . --target install
RUN apt-get install -y graphviz
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment