Skip to content

Commit

Permalink
Update Dockerfiles for build environment
Browse files Browse the repository at this point in the history
  • Loading branch information
jnippula committed Sep 4, 2024
1 parent a2140e5 commit 597cfa8
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
4 changes: 4 additions & 0 deletions packaging/Dockerfile.build_env
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@ RUN mkdir -p /artifacts && chown -R builder:builder /artifacts

USER builder

# Define Rust compiler
ENV RUSTUP_HOME=/opt/rust CARGO_HOME=/home/builder/.cargo
ENV PATH=$PATH:/opt/rust/bin

VOLUME /px4-firmware/sources
WORKDIR /px4-firmware/sources

Expand Down
6 changes: 6 additions & 0 deletions packaging/Dockerfile.build_env_pre
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,12 @@ RUN apt-get update && apt-get install -y --no-install-recommends \

RUN mkdir -p /tools

# Install Rust compiler
ENV RUSTUP_HOME /opt/rust
ENV CARGO_HOME /opt/rust
RUN curl https://sh.rustup.rs -sSf | sh -s -- -y --no-modify-path
RUN /opt/rust/bin/rustup target add riscv64gc-unknown-none-elf

RUN curl -LOs https://static.dev.sifive.com/dev-tools/freedom-tools/v2020.12/riscv64-unknown-elf-toolchain-10.2.0-2020.12.8-x86_64-linux-ubuntu14.tar.gz && \
tar xf riscv64-unknown-elf-toolchain-10.2.0-2020.12.8-x86_64-linux-ubuntu14.tar.gz -C /tools && \
rm -f riscv64-unknown-elf-toolchain-10.2.0-2020.12.8-x86_64-linux-ubuntu14.tar.gz
Expand Down

0 comments on commit 597cfa8

Please sign in to comment.