diff --git a/src/ci/docker/host-x86_64/aarch64-android/Dockerfile b/src/ci/docker/host-x86_64/aarch64-android/Dockerfile new file mode 100644 index 0000000000000..497cfff04b2ff --- /dev/null +++ b/src/ci/docker/host-x86_64/aarch64-android/Dockerfile @@ -0,0 +1,41 @@ +FROM ubuntu:23.04 + +ARG DEBIAN_FRONTEND=noninteractive +COPY scripts/android-base-apt-get.sh /scripts/ +RUN sh /scripts/android-base-apt-get.sh + +COPY scripts/android-ndk.sh /scripts/ +RUN . /scripts/android-ndk.sh && \ + download_ndk android-ndk-r26d-linux.zip + +RUN dpkg --add-architecture i386 && \ + apt-get update && \ + apt-get install -y --no-install-recommends \ + libgl1-mesa-glx \ + libpulse0 \ + libstdc++6:i386 \ + openjdk-8-jre-headless \ + tzdata \ + wget \ + python3 + +COPY scripts/android-sdk.sh /scripts/ +COPY scripts/android-sdk-manager.py /scripts/ +COPY host-x86_64/aarch64-android/android-sdk.lock /android/sdk/android-sdk.lock +RUN /scripts/android-sdk.sh + +ENV PATH=$PATH:/android/sdk/emulator +ENV PATH=$PATH:/android/sdk/tools +ENV PATH=$PATH:/android/sdk/platform-tools + +ENV TARGETS=aarch64-linux-android + +ENV RUST_CONFIGURE_ARGS --android-ndk=/android/ndk/ + +ENV SCRIPT python3 ../x.py --stage 2 test --host='' --target $TARGETS + +COPY scripts/sccache.sh /scripts/ +RUN sh /scripts/sccache.sh + +COPY scripts/android-start-emulator.sh /scripts/ +ENTRYPOINT ["/scripts/android-start-emulator.sh", "arm64-v8a", "auto"] diff --git a/src/ci/docker/host-x86_64/aarch64-android/android-sdk.lock b/src/ci/docker/host-x86_64/aarch64-android/android-sdk.lock new file mode 100644 index 0000000000000..fd73b0e280ecc --- /dev/null +++ b/src/ci/docker/host-x86_64/aarch64-android/android-sdk.lock @@ -0,0 +1,6 @@ +emulator emulator-linux_x64-11772612.zip 974ad0591834a9fa3db307e49cdba352462e5f1e +patcher;v4 3534162-studio.sdk-patcher.zip 046699c5e2716ae11d77e0bad814f7f33fab261e +platform-tools platform-tools_r34.0.5-linux.zip 96097475cf7b279fdd8f218f5d043ffe94104ec3 +platforms;android-21 android-21_r02.zip 53536556059bb29ae82f414fd2e14bc335a4eb4c +system-images;android-21;default;arm64-v8a sys-img/android/arm64-v8a-21_r04.zip c4375f1b4b4cd21a8617660e25f621cedcbd8332 +tools sdk-tools-linux-4333796.zip 8c7c28554a32318461802c1291d76fccfafde054 diff --git a/src/ci/docker/host-x86_64/arm-android/Dockerfile b/src/ci/docker/host-x86_64/arm-android/Dockerfile index 222fa8a7355c8..a15e517a764ff 100644 --- a/src/ci/docker/host-x86_64/arm-android/Dockerfile +++ b/src/ci/docker/host-x86_64/arm-android/Dockerfile @@ -38,4 +38,4 @@ COPY scripts/sccache.sh /scripts/ RUN sh /scripts/sccache.sh COPY scripts/android-start-emulator.sh /scripts/ -ENTRYPOINT ["/scripts/android-start-emulator.sh"] +ENTRYPOINT ["/scripts/android-start-emulator.sh", "armeabi-v7a", "classic"] diff --git a/src/ci/docker/scripts/android-start-emulator.sh b/src/ci/docker/scripts/android-start-emulator.sh index 09f0d13759c79..fac1421585c52 100755 --- a/src/ci/docker/scripts/android-start-emulator.sh +++ b/src/ci/docker/scripts/android-start-emulator.sh @@ -6,11 +6,9 @@ set -ex # emulator identify the system export SHELL=/bin/bash -# Using the default qemu2 engine makes time::tests::since_epoch fails because -# the emulator date is set to unix epoch (in armeabi-v7a-18 image). Using -# classic engine the emulator starts with the current date and the tests run -# fine. If another image is used, this need to be evaluated again. -nohup nohup emulator @armeabi-v7a-18 \ - -engine classic -no-window -partition-size 2047 0<&- &>/dev/null & +nohup nohup emulator @$1-21 \ + -engine $2 -no-window -no-audio -partition-size 2047 0<&- &>/dev/null & + +shift 2 exec "$@" diff --git a/src/ci/github-actions/jobs.yml b/src/ci/github-actions/jobs.yml index 04888dc09b50d..0f2182a7920f0 100644 --- a/src/ci/github-actions/jobs.yml +++ b/src/ci/github-actions/jobs.yml @@ -110,6 +110,9 @@ auto: - image: arm-android <<: *job-linux-8c + - image: aarch64-android + <<: *job-linux-8c + - image: armhf-gnu <<: *job-linux-8c