-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Dockerfile to simplify build process #40
Conversation
to demonstrate cmake issues
to demonstrate cmake issues
to demonstrate cmake issues
by relaxing normal build conventions to demonstrate cmake issues
I've added a few more commits to demonstrate the issues with the existing CMake. > docker build \
--target=exporter \
--output=build .
[+] Building 6.3s (12/14) docker:default
=> [internal] load build definition from Dockerfile 0.0s
=> => transferring dockerfile: 2.11kB 0.0s
=> [internal] load metadata for docker.io/library/ros:jazzy 1.5s
=> [internal] load .dockerignore 0.0s
=> => transferring context: 210B 0.0s
=> [base 1/2] FROM docker.io/library/ros:jazzy@sha256:ee4862fe098e18eba8fb0e9843d57241e404aea12bcba57ed037827f16d98ba6 0.0s
=> [internal] load build context 0.0s
=> => transferring context: 1.53kB 0.0s
=> CACHED [base 2/2] RUN mv /etc/apt/apt.conf.d/docker-clean /etc/apt/ && echo 'Binary::apt::APT::Keep-Downloaded-Packages "true";' > /etc/apt/apt.conf. 0.0s
=> CACHED [prepper 1/3] WORKDIR /opt/rgl 0.0s
=> CACHED [prepper 2/3] COPY package.xml src/RGLGazeboPlugin/package.xml 0.0s
=> CACHED [prepper 3/3] RUN --mount=type=cache,sharing=locked,target=/var/cache/apt rosdep install -y --from-paths src --ignore-src 0.0s
=> CACHED [builder 1/3] COPY . /tmp/RGLGazeboPlugin 0.0s
=> CACHED [builder 2/3] RUN --mount=type=cache,target=src/,rw cp -r /tmp/RGLGazeboPlugin src/RGLGazeboPlugin 0.0s
=> ERROR [builder 3/3] RUN --mount=type=cache,target=src/,ro . /opt/ros/jazzy/setup.sh && colcon build 4.6s
------
> [builder 3/3] RUN --mount=type=cache,target=src/,ro . /opt/ros/jazzy/setup.sh && colcon build:
0.882 WARNING: Package name "RGLGazeboPlugin" does not follow the naming conventions. It should start with a lower case letter and only contain lower case letters, digits, underscores, and dashes.
0.918 Starting >>> RGLGazeboPlugin
4.342 --- stderr: RGLGazeboPlugin
4.342 CMake Error at RGLServerPlugin/CMakeLists.txt:47 (file):
4.342 file DOWNLOAD cannot open file for write.
4.342
4.342
4.342 ---
4.342 Failed <<< RGLGazeboPlugin [3.42s, exited with code 1]
4.400
4.400 Summary: 0 packages finished [3.60s]
4.400 1 package failed: RGLGazeboPlugin
4.400 1 package had stderr output: RGLGazeboPlugin
------
Dockerfile:38
--------------------
37 |
38 | >>> RUN --mount=type=cache,target=src/,ro \
39 | >>> . /opt/ros/$ROS_DISTRO/setup.sh && \
40 | >>> colcon build
41 |
--------------------
ERROR: failed to solve: process "/bin/sh -c . /opt/ros/$ROS_DISTRO/setup.sh && colcon build" did not complete successfully: exit code: 1 Note: reverting 3f69342 will not produce the expected built output, but avoids violating the expected CMake/colcon norms. |
This commit changes RGL download directory from SOURCE_DIR to BINARY_DIR
now that cmake behaves
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
Thank you for your contribution.
Since #42 has been merged, please change the base branch to main
. I will merge it then.
Done! |
No description provided.