6 ############### Install packages for building
7 dpkg
--add-architecture ${DEBIAN_ARCH}
8 echo 'deb-src https://deb.debian.org/debian testing main' > /etc
/apt
/sources.list.d
/deb-src.list
10 apt-get
-y install ca-certificates
11 apt-get
-y install --no-install-recommends \
12 crossbuild-essential-
${DEBIAN_ARCH} \
45 libdrm-dev
:${DEBIAN_ARCH} \
46 libx11-dev
:${DEBIAN_ARCH} \
47 libxxf86vm-dev
:${DEBIAN_ARCH} \
48 libexpat1-dev
:${DEBIAN_ARCH} \
49 libsensors-dev
:${DEBIAN_ARCH} \
50 libxfixes-dev
:${DEBIAN_ARCH} \
51 libxdamage-dev
:${DEBIAN_ARCH} \
52 libxext-dev
:${DEBIAN_ARCH} \
53 x11proto-dev
:${DEBIAN_ARCH} \
54 libx11-xcb-dev
:${DEBIAN_ARCH} \
55 libxcb-dri2-0-dev
:${DEBIAN_ARCH} \
56 libxcb-glx0-dev
:${DEBIAN_ARCH} \
57 libxcb-xfixes0-dev
:${DEBIAN_ARCH} \
58 libxcb-dri3-dev
:${DEBIAN_ARCH} \
59 libxcb-present-dev
:${DEBIAN_ARCH} \
60 libxcb-randr0-dev
:${DEBIAN_ARCH} \
61 libxcb-sync-dev
:${DEBIAN_ARCH} \
62 libxrandr-dev
:${DEBIAN_ARCH} \
63 libxshmfence-dev
:${DEBIAN_ARCH} \
64 libelf-dev
:${DEBIAN_ARCH} \
65 zlib1g-dev
:${DEBIAN_ARCH} \
66 libglvnd-core-dev
:${DEBIAN_ARCH} \
67 libgles2-mesa-dev
:${DEBIAN_ARCH} \
68 libegl1-mesa-dev
:${DEBIAN_ARCH} \
69 libpng-dev
:${DEBIAN_ARCH}
71 ############### Cross-build dEQP
72 mkdir
-p /artifacts
/rootfs
/deqp
74 git config
--global user.email
"mesa@example.com"
75 git config
--global user.name
"Mesa CI"
76 # XXX: Use --depth 1 once we can drop the cherry-picks.
78 https
://github.com
/KhronosGroup
/VK-GL-CTS.git \
79 -b opengl-es-cts-3.2
.5.1 \
82 # Fix surfaceless build
83 git cherry-pick
-x 22f41e5e321c6dcd8569c4dad91bce89f06b3670
84 git cherry-pick
-x 1daa8dff73161ea60ead965bd6c9f2a0a2165648
86 # surfaceless links against libkms and such despite not using it.
87 sed -i '/gbm/d' targets
/surfaceless
/surfaceless.cmake
88 sed -i '/libkms/d' targets
/surfaceless
/surfaceless.cmake
89 sed -i '/libgbm/d' targets
/surfaceless
/surfaceless.cmake
91 python3 external
/fetch_sources.py
93 cd /artifacts
/rootfs
/deqp
95 -DDEQP_TARGET=surfaceless \
96 -DCMAKE_BUILD_TYPE=Release \
97 -DCMAKE_C_COMPILER=${GCC_ARCH}-gcc \
98 -DCMAKE_CXX_COMPILER=${GCC_ARCH}-g++ \
101 rm -rf /artifacts
/rootfs
/deqp
/external
102 rm -rf /artifacts
/rootfs
/deqp
/modules
/gles31
103 rm -rf /artifacts
/rootfs
/deqp
/modules
/internal
104 rm -rf /artifacts
/rootfs
/deqp
/executor
105 rm -rf /artifacts
/rootfs
/deqp
/execserver
106 rm -rf /artifacts
/rootfs
/deqp
/modules
/egl
107 rm -rf /artifacts
/rootfs
/deqp
/framework
108 find .
-name CMakeFiles |
xargs rm -rf
109 find .
-name lib\
*.a |
xargs rm -rf
114 ############### Cross-build Volt dEQP runner
117 wget https
://github.com
/VoltLang
/Battery
/releases
/download
/v0.1
.23/battery-0.1
.23-x86_64-linux.
tar.gz
118 tar xzvf battery-0.1
.23-x86_64-linux.
tar.gz
119 rm battery-0.1
.23-x86_64-linux.
tar.gz
120 mv battery
/usr
/local
/bin
125 mkdir
-p Watt Volta dEQP
126 wget
-qO- https
://github.com
/VoltLang
/Watt
/archive
/v0.1
.3.
tar.gz |
tar -xz --strip-components=1 -C .
/Watt
127 wget
-qO- https
://github.com
/VoltLang
/Volta
/archive
/v0.1
.3.
tar.gz |
tar -xz --strip-components=1 -C .
/Volta
128 wget
-qO- https
://github.com
/Wallbraker
/dEQP
/archive
/v0.1
.4.
tar.gz |
tar -xz --strip-components=1 -C .
/dEQP
129 battery config
--release --lto Volta Watt
131 battery config
--arch ${VOLT_ARCH} --cmd-volta Volta
/volta Volta
/rt Watt dEQP
133 rm /usr
/local
/bin
/battery
134 cp dEQP
/deqp
/artifacts
/rootfs
/deqp
/deqp-volt
138 ############### Remove LLVM now, so the container image is smaller
139 apt-get
-y remove \
*llvm\
*
142 ############### Cross-build kernel
143 KERNEL_URL
="https://gitlab.freedesktop.org/tomeu/linux/-/archive/v5.5-rc1-panfrost-fixes/linux-v5.5-rc1-panfrost-fixes.tar.gz"
144 export ARCH
=${KERNEL_ARCH}
145 export CROSS_COMPILE
="${GCC_ARCH}-"
148 wget
-qO- ${KERNEL_URL} |
tar -xz --strip-components=1 -C /kernel
150 .
/scripts
/kconfig
/merge_config.sh
${DEFCONFIG} /tmp
/clone
/.gitlab-ci
/${KERNEL_ARCH}.config
151 make -j12 ${KERNEL_IMAGE_NAME} dtbs
152 cp arch
/${KERNEL_ARCH}/boot
/${KERNEL_IMAGE_NAME} /artifacts
/.
153 cp ${DEVICE_TREES} /artifacts
/.
157 ############### Create rootfs
158 cp /tmp
/clone
/.gitlab-ci
/create-rootfs.sh
/artifacts
/rootfs
/.
159 mkdir
-p /artifacts
/rootfs
/bin
160 cp /usr
/bin
/qemu-aarch64-static
/artifacts
/rootfs
/bin
161 cp /usr
/bin
/qemu-arm-static
/artifacts
/rootfs
/bin
164 debootstrap
--variant=minbase
--arch=${DEBIAN_ARCH} testing
/artifacts
/rootfs
/ http
://deb.debian.org
/debian
165 cat /artifacts
/rootfs
/debootstrap
/debootstrap.log
167 chroot
/artifacts
/rootfs sh
/create-rootfs.sh
169 rm /artifacts
/rootfs
/bin
/qemu-arm-static
170 rm /artifacts
/rootfs
/bin
/qemu-aarch64-static
171 rm /artifacts
/rootfs
/create-rootfs.sh