Skip to content

Commit

Permalink
Add some more comments about where configuration comes in
Browse files Browse the repository at this point in the history
  • Loading branch information
alexcrichton committed Jul 22, 2024
1 parent 1d5bf4a commit 350ac54
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 0 deletions.
6 changes: 6 additions & 0 deletions ci/docker/Dockerfile.arm64-linux
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
FROM wasi-sdk-builder-base

# Install an extra C++ toolchain which can target arm64 linux.
RUN apt-get install -y g++-aarch64-linux-gnu

# Configure Rust to use this new compiler for linking Rust executables.
ENV CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER aarch64-linux-gnu-gcc

# Note that `.github/workflows/main.yml` sets various bits and bobs of
# configuration and cmake flags that may get passed to the underlying build. For
# example LLVM is instructed to use the toolchain installed above.
6 changes: 6 additions & 0 deletions ci/docker/Dockerfile.common
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

FROM ubuntu:18.04

# Various build tooling and such necessary to build LLVM and a wasi-sysroot
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
ccache \
Expand All @@ -16,6 +17,8 @@ RUN apt-get update \
unzip \
xz-utils

# Install a more recent version of CMake than what 18.04 has since that's what
# LLVM requires.
RUN curl -sSLO https://github.com/Kitware/CMake/releases/download/v3.29.5/cmake-3.29.5-linux-x86_64.tar.gz \
&& tar xf cmake-3.29.5-linux-x86_64.tar.gz \
&& rm cmake-3.29.5-linux-x86_64.tar.gz \
Expand All @@ -24,9 +27,12 @@ RUN curl -sSLO https://github.com/Kitware/CMake/releases/download/v3.29.5/cmake-

ENV PATH /opt/cmake/bin:$PATH

# As with CMake install a later version of Ninja than waht 18.04 has.
RUN curl -sSLO https://github.com/ninja-build/ninja/releases/download/v1.12.1/ninja-linux.zip \
&& unzip ninja-linux.zip \
&& rm *.zip \
&& mv ninja /opt/cmake/bin

# Tell programs to cache in a location that both isn't a `--volume` mounted root
# and isn't `/root` in the container as that won't be writable during the build.
ENV XDG_CACHE_HOME /tmp/cache
6 changes: 6 additions & 0 deletions ci/docker/Dockerfile.x86_64-linux
Original file line number Diff line number Diff line change
@@ -1 +1,7 @@
FROM wasi-sdk-builder-base

# No extra configuration necessary for x86_64 over what `Dockerfile.common`
# already has.
#
# Note though that `.github/workflows/main.yml` still sets various bits and bobs
# of configuration and cmake flags that may get passed to the underlying build.

0 comments on commit 350ac54

Please sign in to comment.