Skip to content
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

ci(stable): fix build issues to prepare for v1.28.0 release #4105

Merged
merged 5 commits into from
Dec 21, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -621,6 +621,7 @@ jobs:
--env LIBZ_SYS_STATIC=1 \
--env SKIP_TESTS="${SKIP_TESTS}" \
--env TARGET="${TARGET}" \
--env INSTALL_BINDGEN=1 \
--init \
--rm \
--tty \
Expand Down Expand Up @@ -785,6 +786,7 @@ jobs:
--env LIBZ_SYS_STATIC=1 \
--env SKIP_TESTS="${SKIP_TESTS}" \
--env TARGET="${TARGET}" \
--env INSTALL_BINDGEN=1 \
--init \
--rm \
--tty \
Expand Down Expand Up @@ -874,6 +876,7 @@ jobs:
- x86_64-linux-android # skip-pr skip-master
- riscv64gc-unknown-linux-gnu # skip-pr skip-master
- loongarch64-unknown-linux-gnu # skip-pr skip-master
- loongarch64-unknown-linux-musl # skip-pr skip-master
include:
- target: x86_64-unknown-linux-gnu
run_tests: YES
Expand Down Expand Up @@ -970,6 +973,7 @@ jobs:
--env LIBZ_SYS_STATIC=1 \
--env SKIP_TESTS="${SKIP_TESTS}" \
--env TARGET="${TARGET}" \
--env INSTALL_BINDGEN=1 \
--init \
--rm \
--tty \
Expand Down
8 changes: 4 additions & 4 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion ci/actions-templates/linux-builds-template.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ jobs: # skip-master skip-pr skip-stable
- x86_64-linux-android # skip-pr skip-master
- riscv64gc-unknown-linux-gnu # skip-pr skip-master
- loongarch64-unknown-linux-gnu # skip-pr skip-master
- loongarch64-unknown-linux-musl # skip-pr skip-master skip-stable
- loongarch64-unknown-linux-musl # skip-pr skip-master
include:
- target: x86_64-unknown-linux-gnu
run_tests: YES
Expand Down Expand Up @@ -137,6 +137,7 @@ jobs: # skip-master skip-pr skip-stable
--env LIBZ_SYS_STATIC=1 \
--env SKIP_TESTS="${SKIP_TESTS}" \
--env TARGET="${TARGET}" \
--env INSTALL_BINDGEN=1 \
--init \
--rm \
--tty \
Expand Down
4 changes: 1 addition & 3 deletions ci/docker/aarch64-unknown-linux-gnu/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@ FROM rust-aarch64-unknown-linux-gnu

# Building `aws-lc-rs` for Linux depends on `gcc-multilib`, `libclang` and `bindgen`.
# See: https://aws.github.io/aws-lc-rs/requirements/linux
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev \
&& curl --proto '=https' --tlsv1.2 -LsSf https://github.com/rust-lang/rust-bindgen/releases/latest/download/bindgen-cli-installer.sh | sh \
&& mv $HOME/.cargo/bin/bindgen /usr/bin
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev

ENV CC_aarch64_unknown_linux_gnu=aarch64-unknown-linux-gnu-gcc \
CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=aarch64-unknown-linux-gnu-gcc
4 changes: 1 addition & 3 deletions ci/docker/aarch64-unknown-linux-musl/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@ FROM rust-aarch64-unknown-linux-musl

# Building `aws-lc-rs` for Linux depends on `gcc-multilib`, `libclang` and `bindgen`.
# See: https://aws.github.io/aws-lc-rs/requirements/linux
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev \
&& curl --proto '=https' --tlsv1.2 -LsSf https://github.com/rust-lang/rust-bindgen/releases/latest/download/bindgen-cli-installer.sh | sh \
&& mv $HOME/.cargo/bin/bindgen /usr/bin
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev

ENV CC_aarch64_unknown_linux_musl=aarch64-linux-musl-gcc \
CARGO_TARGET_AARCH64_UNKNOWN_LINUX_MUSL_LINKER=aarch64-linux-musl-gcc \
Expand Down
4 changes: 1 addition & 3 deletions ci/docker/android/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@ FROM rust-android

# Building `aws-lc-rs` for Linux depends on `gcc-multilib`, `libclang` and `bindgen`.
# See: https://aws.github.io/aws-lc-rs/requirements/linux
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev \
&& curl --proto '=https' --tlsv1.2 -LsSf https://github.com/rust-lang/rust-bindgen/releases/latest/download/bindgen-cli-installer.sh | sh \
&& mv $HOME/.cargo/bin/bindgen /usr/bin
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev

ENV PATH=$PATH:/android/ndk/toolchains/llvm/prebuilt/linux-x86_64/bin \
ANDROID_NDK=/android/ndk/ \
Expand Down
4 changes: 1 addition & 3 deletions ci/docker/arm-unknown-linux-gnueabi/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@ FROM rust-arm-unknown-linux-gnueabi

# Building `aws-lc-rs` for Linux depends on `gcc-multilib`, `libclang` and `bindgen`.
# See: https://aws.github.io/aws-lc-rs/requirements/linux
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev \
&& curl --proto '=https' --tlsv1.2 -LsSf https://github.com/rust-lang/rust-bindgen/releases/latest/download/bindgen-cli-installer.sh | sh \
&& mv $HOME/.cargo/bin/bindgen /usr/bin
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev

ENV CC_arm_unknown_linux_gnueabi=arm-unknown-linux-gnueabi-gcc \
CARGO_TARGET_ARM_UNKNOWN_LINUX_GNUEABI_LINKER=arm-unknown-linux-gnueabi-gcc
4 changes: 1 addition & 3 deletions ci/docker/arm-unknown-linux-gnueabihf/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@ FROM rust-arm-unknown-linux-gnueabihf

# Building `aws-lc-rs` for Linux depends on `gcc-multilib`, `libclang` and `bindgen`.
# See: https://aws.github.io/aws-lc-rs/requirements/linux
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev \
&& curl --proto '=https' --tlsv1.2 -LsSf https://github.com/rust-lang/rust-bindgen/releases/latest/download/bindgen-cli-installer.sh | sh \
&& mv $HOME/.cargo/bin/bindgen /usr/bin
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev

ENV CC_arm_unknown_linux_gnueabihf=arm-unknown-linux-gnueabihf-gcc \
CARGO_TARGET_ARM_UNKNOWN_LINUX_GNUEABIHF_LINKER=arm-unknown-linux-gnueabihf-gcc
4 changes: 1 addition & 3 deletions ci/docker/armv7-unknown-linux-gnueabihf/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@ FROM rust-armv7-unknown-linux-gnueabihf

# Building `aws-lc-rs` for Linux depends on `gcc-multilib`, `libclang` and `bindgen`.
# See: https://aws.github.io/aws-lc-rs/requirements/linux
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev \
&& curl --proto '=https' --tlsv1.2 -LsSf https://github.com/rust-lang/rust-bindgen/releases/latest/download/bindgen-cli-installer.sh | sh \
&& mv $HOME/.cargo/bin/bindgen /usr/bin
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev

ENV CC_armv7_unknown_linux_gnueabihf=armv7-unknown-linux-gnueabihf-gcc \
CARGO_TARGET_ARMV7_UNKNOWN_LINUX_GNUEABIHF_LINKER=armv7-unknown-linux-gnueabihf-gcc
17 changes: 7 additions & 10 deletions ci/docker/i686-unknown-linux-gnu/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@
FROM rust-i686-unknown-linux-gnu

# Building `aws-lc-rs` for Linux depends on `gcc-multilib`, `libclang` and `bindgen`.
# See: https://aws.github.io/aws-lc-rs/requirements/linux
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev \
&& curl --proto '=https' --tlsv1.2 -LsSf https://github.com/rust-lang/rust-bindgen/releases/latest/download/bindgen-cli-installer.sh | sh \
&& mv $HOME/.cargo/bin/bindgen /usr/bin

# Install `perl-IPC-Cmd` to make OpenSSL v3 happy.
# See: <https://github.com/sfackler/rust-openssl/issues/1550>
RUN yum upgrade -y && \
yum install -y perl-IPC-Cmd
# Install `perl-IPC-Cmd` to make OpenSSL v3 happy.
# See: <https://github.com/sfackler/rust-openssl/issues/1550>
RUN yum upgrade -y && \
yum install -y perl-IPC-Cmd \
# Building `aws-lc-rs` for Linux depends on `gcc-multilib`, `libclang` and `bindgen`.
# See: https://aws.github.io/aws-lc-rs/requirements/linux
glibc-devel.i686 clang-libs
4 changes: 1 addition & 3 deletions ci/docker/loongarch64-unknown-linux-gnu/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@ FROM rust-loongarch64-unknown-linux-gnu

# Building `aws-lc-rs` for Linux depends on `gcc-multilib`, `libclang` and `bindgen`.
# See: https://aws.github.io/aws-lc-rs/requirements/linux
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev \
&& curl --proto '=https' --tlsv1.2 -LsSf https://github.com/rust-lang/rust-bindgen/releases/latest/download/bindgen-cli-installer.sh | sh \
&& mv $HOME/.cargo/bin/bindgen /usr/bin
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev

ENV CC_loongarch64_unknown_linux_gnu=loongarch64-unknown-linux-gnu-gcc \
CARGO_TARGET_LOONGARCH64_UNKNOWN_LINUX_GNU_LINKER=loongarch64-unknown-linux-gnu-gcc
4 changes: 1 addition & 3 deletions ci/docker/loongarch64-unknown-linux-musl/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@ FROM rust-loongarch64-unknown-linux-musl

# Building `aws-lc-rs` for Linux depends on `gcc-multilib`, `libclang` and `bindgen`.
# See: https://aws.github.io/aws-lc-rs/requirements/linux
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev \
&& curl --proto '=https' --tlsv1.2 -LsSf https://github.com/rust-lang/rust-bindgen/releases/latest/download/bindgen-cli-installer.sh | sh \
&& mv $HOME/.cargo/bin/bindgen /usr/bin
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev

ENV CC_loongarch64_unknown_linux_musl=loongarch64-unknown-linux-musl-gcc \
CARGO_TARGET_LOONGARCH64_UNKNOWN_LINUX_MUSL_LINKER=loongarch64-unknown-linux-musl-gcc
4 changes: 1 addition & 3 deletions ci/docker/powerpc-unknown-linux-gnu/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@ FROM rust-powerpc-unknown-linux-gnu

# Building `aws-lc-rs` for Linux depends on `gcc-multilib`, `libclang` and `bindgen`.
# See: https://aws.github.io/aws-lc-rs/requirements/linux
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev \
&& curl --proto '=https' --tlsv1.2 -LsSf https://github.com/rust-lang/rust-bindgen/releases/latest/download/bindgen-cli-installer.sh | sh \
&& mv $HOME/.cargo/bin/bindgen /usr/bin
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev

ENV CC_powerpc_unknown_linux_gnu=powerpc-unknown-linux-gnu-gcc \
CARGO_TARGET_POWERPC_UNKNOWN_LINUX_GNU_LINKER=powerpc-unknown-linux-gnu-gcc
4 changes: 1 addition & 3 deletions ci/docker/powerpc64-unknown-linux-gnu/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@ FROM rust-powerpc64-unknown-linux-gnu

# Building `aws-lc-rs` for Linux depends on `gcc-multilib`, `libclang` and `bindgen`.
# See: https://aws.github.io/aws-lc-rs/requirements/linux
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev \
&& curl --proto '=https' --tlsv1.2 -LsSf https://github.com/rust-lang/rust-bindgen/releases/latest/download/bindgen-cli-installer.sh | sh \
&& mv $HOME/.cargo/bin/bindgen /usr/bin
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev

ENV CC_powerpc64_unknown_linux_gnu=powerpc64-unknown-linux-gnu-gcc \
CARGO_TARGET_POWERPC64_UNKNOWN_LINUX_GNU_LINKER=powerpc64-unknown-linux-gnu-gcc
4 changes: 1 addition & 3 deletions ci/docker/powerpc64le-unknown-linux-gnu/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@ FROM rust-powerpc64le-unknown-linux-gnu

# Building `aws-lc-rs` for Linux depends on `gcc-multilib`, `libclang` and `bindgen`.
# See: https://aws.github.io/aws-lc-rs/requirements/linux
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev \
&& curl --proto '=https' --tlsv1.2 -LsSf https://github.com/rust-lang/rust-bindgen/releases/latest/download/bindgen-cli-installer.sh | sh \
&& mv $HOME/.cargo/bin/bindgen /usr/bin
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev

ENV CC_powerpc64le_unknown_linux_gnu=powerpc64le-linux-gnu-gcc \
CARGO_TARGET_POWERPC64LE_UNKNOWN_LINUX_GNU_LINKER=powerpc64le-linux-gnu-gcc
4 changes: 1 addition & 3 deletions ci/docker/riscv64gc-unknown-linux-gnu/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@ FROM rust-riscv64gc-unknown-linux-gnu

# Building `aws-lc-rs` for Linux depends on `gcc-multilib`, `libclang` and `bindgen`.
# See: https://aws.github.io/aws-lc-rs/requirements/linux
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev \
&& curl --proto '=https' --tlsv1.2 -LsSf https://github.com/rust-lang/rust-bindgen/releases/latest/download/bindgen-cli-installer.sh | sh \
&& mv $HOME/.cargo/bin/bindgen /usr/bin
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev

ENV CC_riscv64gc_unknown_linux_gnu=riscv64-unknown-linux-gnu-gcc \
CARGO_TARGET_RISCV64GC_UNKNOWN_LINUX_GNU_LINKER=riscv64-unknown-linux-gnu-gcc
4 changes: 1 addition & 3 deletions ci/docker/s390x-unknown-linux-gnu/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@ FROM rust-s390x-unknown-linux-gnu

# Building `aws-lc-rs` for Linux depends on `gcc-multilib`, `libclang` and `bindgen`.
# See: https://aws.github.io/aws-lc-rs/requirements/linux
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev \
&& curl --proto '=https' --tlsv1.2 -LsSf https://github.com/rust-lang/rust-bindgen/releases/latest/download/bindgen-cli-installer.sh | sh \
&& mv $HOME/.cargo/bin/bindgen /usr/bin
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev

ENV CC_s390x_unknown_linux_gnu=s390x-ibm-linux-gnu-gcc \
CARGO_TARGET_S390X_UNKNOWN_LINUX_GNU_LINKER=s390x-ibm-linux-gnu-gcc
4 changes: 4 additions & 0 deletions ci/docker/x86_64-unknown-freebsd/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
FROM rust-x86_64-unknown-freebsd

# Building `aws-lc-rs` for FreeBSD on Linux depends on `gcc-multilib`, `libclang` and `bindgen`.
# See: https://aws.github.io/aws-lc-rs/requirements/linux
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev

ENV CC_x86_64_unknown_freebsd=x86_64-unknown-freebsd12-clang \
CARGO_TARGET_X86_64_UNKNOWN_FREEBSD_LINKER=x86_64-unknown-freebsd12-clang
4 changes: 4 additions & 0 deletions ci/docker/x86_64-unknown-illumos/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
FROM rust-x86_64-unknown-illumos

# Building `aws-lc-rs` for Illumos on Linux depends on `gcc-multilib`, `libclang` and `bindgen`.
# See: https://aws.github.io/aws-lc-rs/requirements/linux
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev

ENV \
AR_x86_64_unknown_illumos="x86_64-illumos-ar" \
RANLIB_x86_64_unknown_illumos="x86_64-illumos-ranlib" \
Expand Down
4 changes: 4 additions & 0 deletions ci/docker/x86_64-unknown-netbsd/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
FROM rust-x86_64-unknown-netbsd

# Building `aws-lc-rs` for NetBSD on Linux depends on `gcc-multilib`, `libclang` and `bindgen`.
# See: https://aws.github.io/aws-lc-rs/requirements/linux
RUN apt-get update && apt-get install -qy gcc-multilib libclang-dev

ENV CARGO_TARGET_X86_64_UNKNOWN_NETBSD_LINKER=x86_64--netbsd-gcc-sysroot
21 changes: 17 additions & 4 deletions ci/run.bash
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,18 @@ export RUST_BACKTRACE=1
rustc -vV
cargo -vV

if [ -n "$INSTALL_BINDGEN" ]; then
if ! curl --proto '=https' --tlsv1.2 -LsSf https://github.com/rust-lang/rust-bindgen/releases/latest/download/bindgen-cli-installer.sh | sh -s -- --no-modify-path \
| grep "everything's installed!";
# Ignoring exit code since the script might fail to write the receipt after a successful installation.
then
cargo install --force --locked bindgen-cli
fi
mkdir "$CARGO_HOME"/bin/bindgen-cli
mv "$CARGO_HOME"/bin/bindgen "$CARGO_HOME"/bin/bindgen-cli/
export PATH="$CARGO_HOME/bin/bindgen-cli:$PATH"
fi


FEATURES=('--no-default-features' '--features' 'curl-backend,reqwest-native-tls')
case "$(uname -s)" in
Expand All @@ -15,11 +27,12 @@ case "$(uname -s)" in
esac

case "$TARGET" in
# these platforms aren't supported by ring:
powerpc* ) ;;
# these platforms aren't supported by aws-lc-rs:
powerpc64* ) ;;
mips* ) ;;
riscv* ) ;;
s390x* ) ;;
loongarch* ) ;;
*netbsd* ) ;;
*illumos* ) ;;
djc marked this conversation as resolved.
Show resolved Hide resolved
# default case, build with rustls enabled
* ) FEATURES+=('--features' 'reqwest-rustls-tls') ;;
esac
Expand Down
Loading