introlab / rtabmap

RTAB-Map library and standalone application
https://introlab.github.io/rtabmap
Other
2.6k stars 761 forks source link

Docker Jammy build error #1292

Open oskarwires opened 1 month ago

oskarwires commented 1 month ago

Hi, I'm having an issue when trying to build the Dockerfile for Jammy (the exact same issue is occuring with the Iron one as well)

=> ERROR [6/6] RUN source /ros_entrypoint.sh &&     cd rtabmap/build &  0.6s 
------                                                                        
 > [6/6] RUN source /ros_entrypoint.sh &&     cd rtabmap/build &&     cmake -DWITH_OPENGV=ON .. &&     make -j$(nproc) &&     make install &&     cd ../.. &&     rm -rf rtabmap &&     ldconfig:
0.553 /bin/sh: line 1: cd: rtabmap/build: No such file or directory
------
Dockerfile:29
--------------------
  28 |     # Build RTAB-Map project
  29 | >>> RUN source /ros_entrypoint.sh && \
  30 | >>>     cd rtabmap/build && \
  31 | >>>     cmake -DWITH_OPENGV=ON .. && \
  32 | >>>     make -j$(nproc) && \
  33 | >>>     make install && \
  34 | >>>     cd ../.. && \
  35 | >>>     rm -rf rtabmap && \
  36 | >>>     ldconfig
  37 |     
--------------------
ERROR: failed to solve: process "/bin/sh -c source /ros_entrypoint.sh &&     cd rtabmap/build &&     cmake -DWITH_OPENGV=ON .. &&     make -j$(nproc) &&     make install &&     cd ../.. &&     rm -rf rtabmap &&     ldconfig" did not complete successfully: exit code: 1

I'm trying to build on Ubuntu 22.04 if that helps

matlabbe commented 1 month ago

From where did you do "docker build" ?

For the COPY to work correctly, we have to launch it from base rtabmap folder:

cd rtabmap
docker build -t rtabmap:jammy -f docker/jammy/Dockerfile .