diff options
| author | Manish Goregaokar <manishsmail@gmail.com> | 2022-11-22 01:26:08 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-11-22 01:26:08 -0500 |
| commit | 952d385121a633db28a0d28d2dbb8289bd0a844f (patch) | |
| tree | ec9a2cb182d7767fd66587a44e6b35b0c279dc69 /src/ci/docker | |
| parent | 3683c43a0577df9d4197b619ae788b5f4ea5d1f2 (diff) | |
| parent | 60546088bcfa9ce210a5b0f92079f7642f3b466b (diff) | |
| download | rust-952d385121a633db28a0d28d2dbb8289bd0a844f.tar.gz rust-952d385121a633db28a0d28d2dbb8289bd0a844f.zip | |
Rollup merge of #104622 - nicholasbishop:bishop-uefi-clang, r=Mark-Simulacrum
Use clang for the UEFI targets This fixes an issue where the C and asm sources built by compiler_builtins were being compiled as ELF objects instead of PE objects. This wasn't noticed before because it doesn't cause compiler_builtins or rustc to fail to build. You only see a failure when a program is built that references one of the symbols in an ELF object. Compiling with clang fixes this because the cc crate converts the UEFI targets into Windows targets that clang understands, causing it to produce PE objects. Also update compiler_builtins to 0.1.84 to pull in some necessary fixes for compiling the UEFI targets with clang. Fixes https://github.com/rust-lang/rust/issues/104326
Diffstat (limited to 'src/ci/docker')
| -rw-r--r-- | src/ci/docker/host-x86_64/dist-various-2/Dockerfile | 6 | ||||
| -rw-r--r-- | src/ci/docker/host-x86_64/test-various/Dockerfile | 5 |
2 files changed, 10 insertions, 1 deletions
diff --git a/src/ci/docker/host-x86_64/dist-various-2/Dockerfile b/src/ci/docker/host-x86_64/dist-various-2/Dockerfile index e1adabaac9b..93ef7dfcbf5 100644 --- a/src/ci/docker/host-x86_64/dist-various-2/Dockerfile +++ b/src/ci/docker/host-x86_64/dist-various-2/Dockerfile @@ -61,6 +61,12 @@ ENV \ AR_i686_unknown_freebsd=i686-unknown-freebsd12-ar \ CC_i686_unknown_freebsd=i686-unknown-freebsd12-clang \ CXX_i686_unknown_freebsd=i686-unknown-freebsd12-clang++ \ + CC_aarch64_unknown_uefi=clang-11 \ + CXX_aarch64_unknown_uefi=clang++-11 \ + CC_i686_unknown_uefi=clang-11 \ + CXX_i686_unknown_uefi=clang++-11 \ + CC_x86_64_unknown_uefi=clang-11 \ + CXX_x86_64_unknown_uefi=clang++-11 \ CC=gcc-8 \ CXX=g++-8 diff --git a/src/ci/docker/host-x86_64/test-various/Dockerfile b/src/ci/docker/host-x86_64/test-various/Dockerfile index b0f35bcb9cc..0bddffa3436 100644 --- a/src/ci/docker/host-x86_64/test-various/Dockerfile +++ b/src/ci/docker/host-x86_64/test-various/Dockerfile @@ -1,6 +1,7 @@ FROM ubuntu:20.04 RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \ + clang-11 \ g++ \ make \ ninja-build \ @@ -67,7 +68,9 @@ ENV MUSL_TARGETS=x86_64-unknown-linux-musl \ ENV MUSL_SCRIPT python3 /checkout/x.py --stage 2 test --host='' --target $MUSL_TARGETS COPY host-x86_64/test-various/uefi_qemu_test /uefi_qemu_test -ENV UEFI_TARGETS=x86_64-unknown-uefi +ENV UEFI_TARGETS=x86_64-unknown-uefi \ + CC_x86_64_unknown_uefi=clang-11 \ + CXX_x86_64_unknown_uefi=clang++-11 ENV UEFI_SCRIPT python3 /checkout/x.py --stage 2 build --host='' --target $UEFI_TARGETS && \ python3 -u /uefi_qemu_test/run.py |
