diff --git a/docker/build-and-run/Dockerfile b/docker/build-and-run/Dockerfile index df26bf9..a2e31be 100644 --- a/docker/build-and-run/Dockerfile +++ b/docker/build-and-run/Dockerfile @@ -1,27 +1,22 @@ FROM docker.io/arm64v8/ros:humble-ros-base WORKDIR /tmp -RUN git clone https://github.com/gsl-lite/gsl-lite && cd gsl-lite -RUN mkdir build && cd build -RUN cmake .. && make -j8 -RUN sudo make install - -RUN git clone https://github.com/catchorg/Catch2 && cd Catch2 -RUN mkdir build && cd build -RUN cmake .. && make -j8 -RUN sudo make install - -RUN git clone https://github.com/fmtlib/fmt && cd fmt -RUN mkdir build && cd build -RUN cmake -DFMT_TEST=OFF .. -RUN make -j8 -RUN sudo make install - -RUN git clone https://github.com/mpusz/mp-units && cd mp-units -RUN mkdir build && cd build -RUN cmake -DMP_UNITS_AS_SYSTEM_HEADERS=ON -DMP_UNITS_BUILD_LA=OFF .. -RUN make -j8 -RUN sudo make install + +RUN git clone https://github.com/gsl-lite/gsl-lite && cd gsl-lite && \ + mkdir build && cd build && \ + cmake .. && make -j8 && \ + sudo make install + +RUN git clone https://github.com/catchorg/Catch2 && cd Catch2 && \ + mkdir build && cd build && \ + cmake .. && make -j8 && \ + sudo make install + +RUN git clone https://github.com/fmtlib/fmt && cd fmt && \ + mkdir build && cd build && \ + cmake -DFMT_TEST=OFF .. && \ + make -j8 && \ + sudo make install RUN mkdir -p /tmp/colcon_ws/src WORKDIR /tmp/colcon_ws/src @@ -29,7 +24,7 @@ RUN git clone --recursive https://github.com/107-systems/viper WORKDIR /tmp/colcon_ws RUN . /opt/ros/humble/setup.sh && \ - colcon_ws build --symlink-install + colcon build COPY start.sh / RUN chmod ugo+x /start.sh diff --git a/docker/build-and-run/start.sh b/docker/build-and-run/start.sh index 3e21bc4..d2629c9 100755 --- a/docker/build-and-run/start.sh +++ b/docker/build-and-run/start.sh @@ -1,5 +1,5 @@ #!/bin/sh -cd tmp/colcon_ws +cd /tmp/colcon_ws . /opt/ros/humble/setup.sh . install/setup.sh ros2 launch viper viper-quad.py diff --git a/docker/devel/Dockerfile b/docker/devel/Dockerfile index dab13ad..0947230 100644 --- a/docker/devel/Dockerfile +++ b/docker/devel/Dockerfile @@ -1,27 +1,22 @@ FROM docker.io/arm64v8/ros:humble-ros-base WORKDIR /tmp -RUN git clone https://github.com/gsl-lite/gsl-lite && cd gsl-lite -RUN mkdir build && cd build -RUN cmake .. && make -j8 -RUN sudo make install -RUN git clone https://github.com/catchorg/Catch2 && cd Catch2 -RUN mkdir build && cd build -RUN cmake .. && make -j8 -RUN sudo make install +RUN git clone https://github.com/gsl-lite/gsl-lite && cd gsl-lite && \ + mkdir build && cd build && \ + cmake .. && make -j8 && \ + sudo make install -RUN git clone https://github.com/fmtlib/fmt && cd fmt -RUN mkdir build && cd build -RUN cmake -DFMT_TEST=OFF .. -RUN make -j8 -RUN sudo make install +RUN git clone https://github.com/catchorg/Catch2 && cd Catch2 && \ + mkdir build && cd build && \ + cmake .. && make -j8 && \ + sudo make install -RUN git clone https://github.com/mpusz/mp-units && cd mp-units -RUN mkdir build && cd build -RUN cmake -DMP_UNITS_AS_SYSTEM_HEADERS=ON -DMP_UNITS_BUILD_LA=OFF .. -RUN make -j8 -RUN sudo make install +RUN git clone https://github.com/fmtlib/fmt && cd fmt && \ + mkdir build && cd build && \ + cmake -DFMT_TEST=OFF .. && \ + make -j8 && \ + sudo make install RUN mkdir -p /tmp/colcon_ws/src WORKDIR /tmp/colcon_ws/src @@ -29,4 +24,4 @@ RUN git clone --recursive https://github.com/107-systems/viper WORKDIR /tmp/colcon_ws RUN . /opt/ros/humble/setup.sh && \ - colcon_ws build --symlink-install + colcon build