2018-05-01 15:53:19 -04:00
|
|
|
# Image: introlab3it/rtabmap:bionic
|
|
|
|
|
|
|
|
|
|
FROM ubuntu:18.04
|
|
|
|
|
|
|
|
|
|
# Install build dependencies
|
|
|
|
|
RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y \
|
|
|
|
|
libsqlite3-dev \
|
|
|
|
|
libpcl-dev \
|
|
|
|
|
git \
|
|
|
|
|
cmake \
|
|
|
|
|
libopencv-dev \
|
|
|
|
|
libproj-dev \
|
|
|
|
|
libqt5svg5-dev \
|
|
|
|
|
libfreenect-dev \
|
|
|
|
|
libopenni2-dev \
|
|
|
|
|
ffmpeg \
|
|
|
|
|
software-properties-common
|
|
|
|
|
|
|
|
|
|
WORKDIR /root/
|
|
|
|
|
|
2018-05-02 16:10:36 -04:00
|
|
|
# GTSAM
|
|
|
|
|
RUN git clone https://bitbucket.org/gtborg/gtsam.git
|
|
|
|
|
RUN cd gtsam && \
|
|
|
|
|
git checkout 4.0.0-alpha2 && \
|
|
|
|
|
mkdir build && \
|
|
|
|
|
cd build && \
|
2018-12-29 17:15:36 -05:00
|
|
|
cmake -DMETIS_SHARED=ON -DGTSAM_BUILD_STATIC_LIBRARY=OFF -DGTSAM_USE_SYSTEM_EIGEN=ON -DGTSAM_BUILD_TESTS=OFF -DGTSAM_BUILD_EXAMPLES_ALWAYS=OFF -DCMAKE_BUILD_TYPE=Release .. && \
|
2018-05-02 16:19:15 -04:00
|
|
|
make -j$(nproc) && \
|
2018-05-02 16:10:36 -04:00
|
|
|
make install && \
|
|
|
|
|
cd && \
|
|
|
|
|
rm -r gtsam
|
|
|
|
|
|
|
|
|
|
# g2o
|
|
|
|
|
RUN git clone https://github.com/RainerKuemmerle/g2o.git
|
|
|
|
|
RUN cd g2o && \
|
|
|
|
|
git checkout 20170730_git && \
|
|
|
|
|
mkdir build && \
|
|
|
|
|
cd build && \
|
2018-12-29 17:15:36 -05:00
|
|
|
cmake -DBUILD_LGPL_SHARED_LIBS=ON -DG2O_BUILD_APPS=OFF -DBUILD_WITH_MARCH_NATIVE=OFF -DG2O_BUILD_EXAMPLES=OFF -DBUILD_SHARED_LIBS=ON -DCMAKE_BUILD_TYPE=Release .. && \
|
2018-05-02 16:19:15 -04:00
|
|
|
make -j$(nproc) && \
|
2018-05-02 16:10:36 -04:00
|
|
|
make install && \
|
|
|
|
|
cd && \
|
|
|
|
|
rm -r g2o
|
|
|
|
|
|
2018-05-03 09:11:27 -04:00
|
|
|
# libpointmatcher
|
2018-05-02 16:10:36 -04:00
|
|
|
RUN git clone https://github.com/ethz-asl/libnabo.git
|
2018-05-03 09:11:27 -04:00
|
|
|
#commit Apr 25 2018
|
2018-05-02 16:10:36 -04:00
|
|
|
RUN cd libnabo && \
|
2018-05-03 09:11:27 -04:00
|
|
|
git checkout 7e378f6765393462357b8b74d8dc8c5554542ae6 && \
|
2018-05-02 16:10:36 -04:00
|
|
|
mkdir build && \
|
|
|
|
|
cd build && \
|
|
|
|
|
cmake -DCMAKE_BUILD_TYPE=Release .. && \
|
2018-05-02 16:19:15 -04:00
|
|
|
make -j$(nproc) && \
|
2018-05-02 16:10:36 -04:00
|
|
|
make install && \
|
|
|
|
|
cd && \
|
|
|
|
|
rm -r libnabo
|
|
|
|
|
RUN git clone https://github.com/ethz-asl/libpointmatcher.git
|
2018-05-03 09:11:27 -04:00
|
|
|
#commit Jan 19 2018
|
2018-05-02 16:10:36 -04:00
|
|
|
RUN cd libpointmatcher && \
|
2018-05-03 09:11:27 -04:00
|
|
|
git checkout 00004bd41e44a1cf8de24ad87e4914760717cbcc && \
|
2018-05-02 16:10:36 -04:00
|
|
|
mkdir build && \
|
|
|
|
|
cd build && \
|
|
|
|
|
cmake -DCMAKE_BUILD_TYPE=Release .. && \
|
2018-05-02 16:19:15 -04:00
|
|
|
make -j$(nproc) && \
|
2018-05-02 16:10:36 -04:00
|
|
|
make install && \
|
|
|
|
|
cd && \
|
|
|
|
|
rm -r libpointmatcher
|
|
|
|
|
|
2018-05-03 09:11:27 -04:00
|
|
|
|
2018-05-01 15:53:19 -04:00
|
|
|
# Clone source code
|
2018-05-03 09:11:27 -04:00
|
|
|
ARG CACHE_DATE=2016-01-01
|
2018-05-01 15:53:19 -04:00
|
|
|
RUN git clone https://github.com/introlab/rtabmap.git
|
|
|
|
|
|
|
|
|
|
# Build RTAB-Map project
|
|
|
|
|
RUN cd rtabmap/build && \
|
|
|
|
|
cmake .. && \
|
|
|
|
|
make -j$(nproc) && \
|
|
|
|
|
make install && \
|
|
|
|
|
cd ../.. && \
|
|
|
|
|
rm -rf rtabmap && \
|
|
|
|
|
ldconfig
|
|
|
|
|
|
|
|
|
|
WORKDIR /root
|
|
|
|
|
|