Commit Graph

33 Commits

Author SHA1 Message Date
Valentine Burley
8339598f07 ci/android: Add build section for uninstalling build software
This was missing compared to the test-gl and test-vk containers.

Signed-off-by: Valentine Burley <valentine.burley@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/34405>
2025-04-08 09:52:28 +00:00
Valentine Burley
f9b6403d46 ci/container: Move calling strip-rootfs.sh to common scripts
No functional changes with the move, this is a cleanup for consistency.
Also, add the usual image tags to the header.

Signed-off-by: Valentine Burley <valentine.burley@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/34405>
2025-04-08 09:52:28 +00:00
Valentine Burley
9f9233c033 ci/android: Add section for downloading Android CTS
Signed-off-by: Valentine Burley <valentine.burley@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/34320>
2025-04-05 09:28:21 +00:00
Valentine Burley
9d11a8304e ci/android: Remove platform-tools from test-android container
Cuttlefish comes with the required tools (under /cuttlefish/bin),
downloading platform-tools isn't necessary.

Signed-off-by: Valentine Burley <valentine.burley@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/34320>
2025-04-05 09:28:21 +00:00
Antonio Ospite
bac77bb30d ci/android: add a job using android-cts instead of deqp-runner
We also want to run Android CTS in the Android jobs.

Since the Android CTS is quite large, download it and strip it down to
only contain the interesting tests, so to reduce the space taken in the
container image.

Eventually we might want to have android-cts be run via deqp-runner
itself, but for now add a proof-of-concept mechanism which calls the
android-cts directly and uses an ad-hoc handling of expectations.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/33499>
2025-03-12 10:29:17 +00:00
Antonio Ospite
ae574a08c6 ci/android: use an x86_64_only cuttlefish image
In .gitlab-ci/cuttlefish-runner.sh 32bit libraries were removed but they
were not being replaced with newer ones, however this caused some
problems because by default the x86_64 target in AOSP is still
multi-library and for example the 32bit zygote process ended up crashing
because of the missing 32bit libraries, causing a general system
instability.

Since the CI is only building 64bit libraries for the android target,
use an x86_64_only cuttlefish product which only has components and
libraries built for the 64bit target, this avoids dealing with 32bit
EGL/Vulkan libraries at all, preventing any possible cause of
instability.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/33499>
2025-03-12 10:29:17 +00:00
Antonio Ospite
3520ed0f2c ci/android: bump CUTTLEFISH_BUILD_NUMBER
Bump CUTTLEFISH_BUILD_NUMBER to get a newer version that fixes some
issues with the `mesa_swrast_guest_angle` GPU_MODE.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/33499>
2025-03-12 10:29:17 +00:00
Guilherme Gallo
a663f97d2d ci: Properly clean up rustup
Use `rustup self uninstall -y` instead of manually removing folders to
ensure a proper cleanup of the rustup installation, including cargo and
init command injections in shell rc files.

Failing to do so can cause issues, such as bash failing to run in a `set
-e` environment due to a missing `$HOME/.cargo/env`, for example.

Signed-off-by: Guilherme Gallo <guilherme.gallo@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/33519>
2025-02-19 05:08:53 +00:00
Valentine Burley
ffdfb0539b ci/android: Add build section for Cuttlefish
Signed-off-by: Valentine Burley <valentine.burley@collabora.com>
Reviewed-by: Antonio Ospite <None>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/33467>
2025-02-12 09:03:48 +00:00
Valentine Burley
05021a1786 ci/angle: Rework building ANGLE (again)
Make setting the ANGLE_ARCH variable optional by providing a default
based on DEBIAN_ARCH, while keeping it possible to override it, which is
expected to be necessary for the Android-arm64 build.

Exclude unnecessary third party dependencies in the .gclient file, which
allows us to delete our first local patch. Thanks to Yuly Novikov for the
suggestion.

Use -no-history for gclient sync, which is equivalent to git's --depth=1
argument. This greatly speeds up the process of fetching sources.

Thanks to this speedup fetching third_party/catapult is no longer an
issue, allowing us to remove our second local patch.

Since we're no longer applying local patches, use ANGLE_REV and
/angle/version as the base for our version check on Android.

Signed-off-by: Valentine Burley <valentine.burley@collabora.com>
Reviewed-by: Antonio Ospite <None>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/33467>
2025-02-12 09:03:48 +00:00
Valentine Burley
0fc4aef848 ci/android: Build and use ANGLE
Signed-off-by: Valentine Burley <valentine.burley@collabora.com>
Reviewed-by: Eric Engestrom <None>
Reviewed-by: Antonio Ospite <None>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/33377>
2025-02-06 11:58:33 +00:00
Valentine Burley
e0f0be6fc8 ci/android: Don't build desktop GL CTS
Android officially only supports GLES, and we don't need the desktop
GL CTS in CI.

Signed-off-by: Valentine Burley <valentine.burley@collabora.com>
Reviewed-by: Eric Engestrom <None>
Reviewed-by: Antonio Ospite <None>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/33377>
2025-02-06 11:58:33 +00:00
Antonio Ospite
4ac5d7c0bd ci/android: pass --allow-downgrades when installing cuttlefish host tools
Pass --allow-downgrades when installing cuttlefish host tools just to
cover the case when the script is run locally.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/33261>
2025-01-29 16:36:59 +00:00
Antonio Ospite
909f837ecf ci/android: update CUTTLEFISH_BUILD_NUMBER
Update CUTTLEFISH_BUILD_NUMBER to use a cuttlefish image that has the
`mesa_swrast` GPU mode which uses llvmpipe for GL and lavapipe for
Vulkan.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/33261>
2025-01-29 16:36:58 +00:00
Antonio Ospite
876c4513a5 ci/android: rename variable ANDROID_NDK to ANDROID_NDK_VERSION
Rename the variable ANDROID_NDK to ANDROID_NDK_VERSION and only use it
to specify the version itself.

This makes it consistent with ANDROID_SDK_VERSION and it is also in
preparation for using the same variable to build ANGLE in the future.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/33188>
2025-01-24 14:15:22 +00:00
Antonio Ospite
4b2996e749 ci/android: use ANDROID_SDK_VERSION when building deqp components
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/33188>
2025-01-24 14:15:22 +00:00
Antonio Ospite
6df997f6bc ci/android: upgrade DEBIAN_TEST_ANDROID_TAG
Also add a note in .gitlab-ci/container/debian/x86_64_test-android.sh
that DEBIAN_TEST_ANDROID_TAG needs to be updated when that file changes
too.

Reviewed-by: Eric Engestrom <None>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30895>
2025-01-02 19:31:41 +00:00
Antonio Ospite
8252ffbf11 ci/android: use a custom kernel when launching cuttlefish
Use a custom kernel when launching cuttlefish, this is needed for
-gpu_mode=venus.

And while at it also clean up the state from previous runs, this seems
to be required when passing a custom kernel.

In this change also pass -enable_bootanimation=false which makes
drm_virgl work, and pass -enable_minimal_mode=true to avoid using some
features which are not really needed.

Note that the file number limit has to be increased too in
.gitlab-ci/cuttlefish-runner.sh for cuttlefish to work properly.

Reviewed-by: Eric Engestrom <None>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30895>
2025-01-02 19:31:41 +00:00
Antonio Ospite
5d539f1a30 ci/android: get custom cuttlefish images from the S3
To test mesa on cuttlefish some special images tailored for upstream
mesa are needed, in particular these images may set properties or add
functionality that enable new use cases for upstream mesa on Android,
like for instance using venus via the vulkan.virtio mesa driver.

So instead of downloading the standard images from Google, get those
custom images from s3.freedesktop.org.

Reviewed-by: Eric Engestrom <None>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30895>
2025-01-02 19:31:41 +00:00
Antonio Ospite
92488c4598 ci/android: add sudo to EPHEMERAL deps for debian/x86_64_test-android.sh
The ./tools/buildutils/build_packages.sh script used by the
android-cuttlefish project built in debian/x86_64_test-android.sh uses
sudo, so install that as an EPHEMERAL dependency.

Also set SUDO_FORCE_REMOVE=yes when removing sudo to avoid some errors.

Reviewed-by: Eric Engestrom <None>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30895>
2025-01-02 19:31:41 +00:00
Antonio Ospite
711c9adb30 ci/android: update version of cuttlefish host tools
Update the version of cuttlefish host tools.

In particular the new version includes the change to be able to increase
the file number limit to 32k, as explained in
https://github.com/google/android-cuttlefish/pull/675

Reviewed-by: Eric Engestrom <None>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30895>
2025-01-02 19:31:41 +00:00
Antonio Ospite
a90d771724 ci/android: build deqp for DEQP_API=VK
Build deqp for DEQP_API=VK by passing -DDEQP_ANDROID_EXE=ON.

Reviewed-by: Eric Engestrom <None>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30895>
2025-01-02 19:31:41 +00:00
Antonio Ospite
3bdb77e378 ci/deqp: replace local android patches with upstream solution
In commit a34982063 (Support standalone executable builds on Android,
2024-09-12) upstream VK-GL-CTS added support for building deqp as an
executable command for Android, this change is included in the vulkan
branch used by build-deqp.sh so the custom patches can be dropped for
the Vulkan CTS build.

After that and by passing -DDEQP_ANDROID_EXE=ON deqp can now be built
with DEQP_API=tools.

[Eric]
Note that the upstream solution seems to be broken on EGL, so GL & GLES
continue to use the local android patches; for more details, see:
https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28168#note_2676128

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28168>
2024-11-27 20:38:05 +00:00
Eric Engestrom
c20e9868bf ci/container: setup sections in all image builds
Several of them don't use sections yet, but let's just have it
everywhere to avoid weird surprised when moving code around and suddenly
a section is used.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32299>
2024-11-22 11:40:56 +01:00
Eric Engestrom
84e855953c ci/deqp: add build of main branch
For now, this just contains the tools unrelated to any API being tested
(`testlog-to-{xml,csv,junit})`.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32250>
2024-11-22 10:16:49 +00:00
Eric Engestrom
9a689b15d9 ci/deqp: avoid downloading 1.47 GiB multiple times
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32250>
2024-11-22 10:16:49 +00:00
Daniel Stone
d741a6766e ci/{b2c,swrast,layered}: Strip unnecessary things from runtime containers
Bring it up to parity with the LAVA and bare-metal containers by
stripping things we don't need at runtime. There is a lot of stuff we
don't need in container images we only use to execute tests, including
but not limited to the system Mesa which can only cause problems. Call
the same strip-rootfs we already run for LAVA to make sure that this
doesn't happen, as well as slimming down the container image.

Signed-off-by: Daniel Stone <daniels@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31281>
2024-10-10 11:05:57 +00:00
Eric Engestrom
9eb50036d4 ci/deqp-runner: set android rust target in the caller (debian/x86_64_test-android.sh)
This also allows non-x86 android which I hope to add some day.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27420>
2024-03-11 19:43:07 +00:00
Eric Engestrom
2ef7b4dfc1 ci/deqp: control the GLES release independently of GL
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27465>
2024-03-01 15:33:11 +00:00
Eric Engestrom
2106092e63 ci/android: use a specific version of android-cuttlefish
Using whatever version is the latest at the time of the image build is
bad practice from a stability & reproducibility point of view, and the
latest version is currently broken, preventing any change that rebuilds
the android image from being merged.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27911>
2024-03-01 11:16:41 +00:00
Eric Engestrom
fb326ef27f ci/deqp: split vk and gl builds
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27250>
2024-01-26 21:49:05 +00:00
David Heidelberg
e4d6da5ba3 ci: bashify scripts, use arrays
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25843>
2023-10-31 01:00:25 +00:00
David Heidelberg
5140ff1948 ci: rename x86 and amd64 to x86_64, armhf to arm32, and i386 to x86_32
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/8049

Reviewed-by: Yonggang Luo <luoyonggang@gmail.com>
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23282>
2023-06-02 21:30:15 +02:00