1#!/bin/bash 2 3set -e 4set -o xtrace 5 6export DEBIAN_FRONTEND=noninteractive 7 8# Ephemeral packages (installed for this script and removed again at the end) 9STABLE_EPHEMERAL=" \ 10 autoconf \ 11 automake \ 12 bc \ 13 bison \ 14 bzip2 \ 15 ccache \ 16 clang-11 \ 17 cmake \ 18 flex \ 19 g++ \ 20 glslang-tools \ 21 libasound2-dev \ 22 libcap-dev \ 23 libclang-cpp11-dev \ 24 libelf-dev \ 25 libfdt-dev \ 26 libgbm-dev \ 27 libgles2-mesa-dev \ 28 libllvmspirvlib-dev \ 29 libpciaccess-dev \ 30 libpng-dev \ 31 libudev-dev \ 32 libvulkan-dev \ 33 libwaffle-dev \ 34 libwayland-dev \ 35 libx11-xcb-dev \ 36 libxcb-dri2-0-dev \ 37 libxext-dev \ 38 libxkbcommon-dev \ 39 libxrender-dev \ 40 llvm-11-dev \ 41 llvm-spirv \ 42 make \ 43 meson \ 44 ocl-icd-opencl-dev \ 45 patch \ 46 pkg-config \ 47 python3-distutils \ 48 wayland-protocols \ 49 wget \ 50 xz-utils \ 51 " 52 53apt-get install -y --no-remove \ 54 $STABLE_EPHEMERAL \ 55 clinfo \ 56 inetutils-syslogd \ 57 iptables \ 58 libclang-common-11-dev \ 59 libclang-cpp11 \ 60 libcap2 \ 61 libegl1 \ 62 libfdt1 \ 63 libllvmspirvlib11 \ 64 libxcb-shm0 \ 65 ocl-icd-libopencl1 \ 66 python3-lxml \ 67 python3-renderdoc \ 68 python3-simplejson \ 69 spirv-tools \ 70 sysvinit-core 71 72 73. .gitlab-ci/container/container_pre_build.sh 74 75############### Build kernel 76 77export DEFCONFIG="arch/x86/configs/x86_64_defconfig" 78export KERNEL_IMAGE_NAME=bzImage 79export KERNEL_ARCH=x86_64 80export DEBIAN_ARCH=amd64 81 82mkdir -p /lava-files/ 83. .gitlab-ci/container/build-kernel.sh 84 85############### Build libdrm 86 87. .gitlab-ci/container/build-libdrm.sh 88 89############### Build libclc 90 91. .gitlab-ci/container/build-libclc.sh 92 93############### Build virglrenderer 94 95. .gitlab-ci/container/build-virglrenderer.sh 96 97############### Build piglit 98 99PIGLIT_OPTS="-DPIGLIT_BUILD_CL_TESTS=ON -DPIGLIT_BUILD_DMA_BUF_TESTS=ON" . .gitlab-ci/container/build-piglit.sh 100 101############### Build Crosvm 102 103. .gitlab-ci/container/build-rust.sh 104. .gitlab-ci/container/build-crosvm.sh 105rm -rf /root/.cargo 106 107############### Build dEQP GL 108 109DEQP_TARGET=surfaceless . .gitlab-ci/container/build-deqp.sh 110 111############### Build apitrace 112 113. .gitlab-ci/container/build-apitrace.sh 114 115############### Uninstall the build software 116 117ccache --show-stats 118 119apt-get purge -y \ 120 $STABLE_EPHEMERAL 121 122apt-get autoremove -y --purge 123