Category

2017년 8월 20일 일요일

install RTAB-Map Tango (APK) by docker


RTAB-Map Tango (APK)
$ docker pull introlab3it/rtabmap:tango
Note that arm64-v8a APK contains both armeabi-v7a and arm64-v8a binaries.
  • Install APK, 2 choices:
    1. Copy file on host computer then install it with adb from there:
      $ docker run --name=rtabmap-tango introlab3it/rtabmap:tango
      $ docker cp rtabmap-tango:/root/rtabmap-tango/build/arm64-v8a/app/android/bin/RTABMap-debug.apk
      .
      $ docker rm rtabmap-tango
      # cleanup container
      $ adb install -r RTABMap-debug.apk
    2. Call adb from container:
      $ docker run --privileged -i -t --rm -v /dev/bus/usb:/dev/bus/usb introlab3it/rtabmap:tango adb install -r rtabmap-tango/build/arm64-v8a/app/android/bin/RTABMap-debug.apk
docker run -it -d
Dockerfile
# Image: introlab3it/rtabmap:zesty

FROM ubuntu:17.04

# Install build dependencies
RUN apt-get update && apt-get install -y \
      libsqlite3-dev \
      libpcl-dev \
      libopencv-dev \
      git \
      cmake \
      libproj-dev \
      libqt5svg5-dev \
      software-properties-common

RUN sed -i 's|/usr/lib/libmpi.so;||g' /usr/lib/x86_64-linux-gnu/cmake/pcl/PCLConfig.cmake

# Clone source code
WORKDIR /root/

# Build RTAB-Map project
RUN cd rtabmap/build && \
    cmake .. && \
    make -j$(nproc) && \
    make install && \
    cd ../.. && \
    rm -rf rtabmap && \
    ldconfig

WORKDIR /root