2 # SPDX-License-Identifier: MIT
6 function generate_testlist {
9 if [ "$line" = "TESTLIST" ] || [ "$line" = "END TESTLIST" ]; then
13 tests=$(echo "$line" | tr ' ' '\n')
15 for test in $tests; do
16 output=$(/igt/libexec/igt-gpu-tools/"$test" --list-subtests || true)
18 if [ -z "$output" ]; then
21 echo "$output" | while read -r subtest; do
26 done < /igt/libexec/igt-gpu-tools/test-list.txt > /igt/libexec/igt-gpu-tools/ci-testlist.txt
30 git clone https://gitlab.freedesktop.org/drm/igt-gpu-tools.git --single-branch --no-checkout
32 git checkout $IGT_VERSION
34 if [[ "$KERNEL_ARCH" = "arm" ]]; then
35 . ../.gitlab-ci/container/create-cross-file.sh armhf
36 EXTRA_MESON_ARGS="--cross-file /cross_file-armhf.txt"
39 MESON_OPTIONS="-Doverlay=disabled \
40 -Dchamelium=disabled \
48 if [[ "$KERNEL_ARCH" = "arm64" ]] || [[ "$KERNEL_ARCH" = "arm" ]]; then
49 MESON_OPTIONS="$MESON_OPTIONS -Dxe_driver=disabled"
53 meson build $MESON_OPTIONS $EXTRA_MESON_ARGS
54 ninja -C build -j${FDO_CI_CONCURRENT:-4} || ninja -C build -j 1
55 ninja -C build install
57 if [[ "$KERNEL_ARCH" = "arm64" ]]; then
58 export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/igt/lib/aarch64-linux-gnu
59 elif [[ "$KERNEL_ARCH" = "arm" ]]; then
60 export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/igt/lib
62 export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/igt/lib64
65 echo "Generating ci-testlist.txt"
69 tar -cf artifacts/igt.tar /igt
71 # Pass needed files to the test stage
72 S3_ARTIFACT_NAME="igt.tar.gz"
73 gzip -c artifacts/igt.tar > ${S3_ARTIFACT_NAME}
74 ci-fairy s3cp --token-file "${S3_JWT_FILE}" ${S3_ARTIFACT_NAME} https://${PIPELINE_ARTIFACTS_BASE}/${KERNEL_ARCH}/${S3_ARTIFACT_NAME}