diff options
Diffstat (limited to 'coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64')
51 files changed, 959 insertions, 0 deletions
diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/01-disable-updates.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/01-disable-updates.sh new file mode 100755 index 00000000..4c9adc5f --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/01-disable-updates.sh @@ -0,0 +1,9 @@ +#!/usr/bin/env bash +# Copyright (C) 2023 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +set -ex + +# Disalbe updates +echo "Disabling auto-upgrades" +sudo sed -i 's/"1"/"0"/g' /etc/apt/apt.conf.d/20auto-upgrades diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/01-disable_net_lso.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/01-disable_net_lso.sh new file mode 100755 index 00000000..81e7d137 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/01-disable_net_lso.sh @@ -0,0 +1,6 @@ +#!/bin/sh +#Copyright (C) 2023 The Qt Company Ltd +#SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +echo "ethtool -K \${DEVICE_IFACE} tso off" | sudo tee -a /etc/NetworkManager/dispatcher.d/pre-up.d/net_tso_off +sudo chmod +x /etc/NetworkManager/dispatcher.d/pre-up.d/net_tso_off diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/01-install_telegraf.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/01-install_telegraf.sh new file mode 100755 index 00000000..729f9003 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/01-install_telegraf.sh @@ -0,0 +1,3 @@ +#!/bin/sh + +"$(dirname "$0")"/../common/unix/telegraf_install.sh diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/01-set-ulimit.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/01-set-ulimit.sh new file mode 100755 index 00000000..e951e82a --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/01-set-ulimit.sh @@ -0,0 +1,8 @@ +#!/usr/bin/env bash +#Copyright (C) 2023 The Qt Company Ltd +#SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +set -ex + +BASEDIR=$(dirname "$0") +"$BASEDIR/../common/linux/set_ulimit.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/01-systemsetup.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/01-systemsetup.sh new file mode 100755 index 00000000..98744822 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/01-systemsetup.sh @@ -0,0 +1,43 @@ +#!/usr/bin/env bash +# Copyright (C) 2017 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +# This script modifies system settings for automated use + +set -ex + +# shellcheck source=../common/unix/check_and_set_proxy.sh +source "${BASH_SOURCE%/*}/../common/unix/check_and_set_proxy.sh" + +NTS_IP=10.212.2.216 + +echo "Set timezone to UTC." +sudo timedatectl set-timezone Etc/UTC +echo "Timeout for blanking the screen (0 = never)" +gsettings set org.gnome.desktop.session idle-delay 0 +echo "Prevents screen lock when screesaver goes active." +gsettings set org.gnome.desktop.screensaver lock-enabled false +echo "Set grub timeout to 0" +sudo sed -i 's|GRUB_TIMEOUT=10|GRUB_TIMEOUT=0|g' /etc/default/grub +sudo update-grub + +# https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1624320 +# Checking if Ubuntu 20.04 works without this +#echo "Setting up workaround for Ubuntu systemd resolve bug" +#sudo rm -f /etc/resolv.conf +#sudo ln -s /run/systemd/resolve/resolv.conf /etc/resolv.conf + +# remove hostname to get unique based on IP address +sudo rm /etc/hostname + +echo "Set Network Test Server address to $NTS_IP in /etc/hosts" +echo "$NTS_IP qt-test-server qt-test-server.qt-test-net" | sudo tee -a /etc/hosts + +echo 'LC_ALL=en_US.UTF8' | sudo tee /etc/default/locale + +if [ "$http_proxy" != "" ]; then + echo "Acquire::http::Proxy \"$proxy\";" | sudo tee -a /etc/apt/apt.conf +fi + +# This script diverts qtlogging.ini file so we don't get debugging related auto-test failures. +sudo dpkg-divert --divert /etc/xdg/QtProject/qtlogging.ini.foo --rename /etc/xdg/QtProject/qtlogging.ini diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/02-apt.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/02-apt.sh new file mode 100755 index 00000000..9a9a5ef2 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/02-apt.sh @@ -0,0 +1,245 @@ +#!/usr/bin/env bash +# Copyright (C) 2022 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +# Install required packages with APT + +# shellcheck source=../common/linux/apt_wait_loop.sh +source "${BASH_SOURCE%/*}/../common/linux/apt_wait_loop.sh" + +echo "Disabling auto update" +sudo sed -i 's/APT::Periodic::Update-Package-Lists "1";/APT::Periodic::Update-Package-Lists "0";/' /etc/apt/apt.conf.d/10periodic +for service in apt-daily.timer apt-daily-upgrade.timer apt-daily.service apt-daily-upgrade.service; do + sudo systemctl stop $service + sudo systemctl disable $service +done + +function set_internal_repo { + + # Stop fetching the dep-11 metadata, since our mirrors do not handle them well + sudo mv /etc/apt/apt.conf.d/50appstream{,.disabled} + + sudo tee "/etc/apt/sources.list" > /dev/null <<-EOC + deb [arch=amd64] http://repo-clones.ci.qt.io/apt-mirror/mirror/ubuntu/ jammy main restricted universe multiverse + deb [arch=amd64] http://repo-clones.ci.qt.io/apt-mirror/mirror/ubuntu/ jammy-updates main restricted universe multiverse + deb [arch=amd64] http://repo-clones.ci.qt.io/apt-mirror/mirror/ubuntu/ jammy-backports main restricted universe + deb [arch=amd64] http://repo-clones.ci.qt.io/apt-mirror/mirror/ubuntu/ jammy-security main restricted universe multiverse + deb [arch=i386] http://repo-clones.ci.qt.io/apt-mirror/mirror/ubuntu/ jammy main restricted + deb [arch=i386] http://repo-clones.ci.qt.io/apt-mirror/mirror/ubuntu/ jammy-updates main restricted + deb [arch=i386] http://repo-clones.ci.qt.io/apt-mirror/mirror/ubuntu/ jammy universe +EOC +} + +(ping -c 3 repo-clones.ci.qt.io && set_internal_repo) || echo "Internal package repository not found. Using public repositories." + +# Make sure needed ca-certificates are available +sudo apt-get install --reinstall ca-certificates + +# Git is not needed by builds themselves, but is nice to have +# immediately as one starts debugging +installPackages+=(git) +# 7zip is a needed decompressing tool +installPackages+=(p7zip-full) +# To be able to mount yocto-cache during builds +installPackages+=(nfs-common) +# libssl-dev provides headers for OpenSSL +installPackages+=(libssl-dev) +# Needed libraries for X11 support accordingly to https://wiki.qt.io/Building_Qt_5_from_Git +installPackages+=("^libxcb.*") +installPackages+=(libxkbcommon-dev) +installPackages+=(libxkbcommon-x11-dev) +installPackages+=(libx11-xcb-dev) +installPackages+=(libglu1-mesa-dev) +installPackages+=(libxrender-dev) +installPackages+=(libxi-dev) +# Enable linking to system dbus +installPackages+=(libdbus-1-dev) +# Needed libraries for WebEngine +installPackages+=(udev) +installPackages+=(libudev-dev) +installPackages+=(libdrm-dev) +installPackages+=(libegl1-mesa-dev) +installPackages+=(libfontconfig1-dev) +installPackages+=(libgbm-dev) +installPackages+=(liblcms2-dev) +installPackages+=(libpci-dev) +installPackages+=(libre2-dev) +installPackages+=(libsnappy-dev) +installPackages+=(libva-dev) +installPackages+=(libvpx-dev) +installPackages+=(libxkbfile-dev) +installPackages+=(libxshmfence-dev) +installPackages+=(libxss-dev) +# installPackages+=(nodejs) too old +installPackages+=(python3-html5lib) + +# Common event loop handling +installPackages+=(libglib2.0-dev) +# MySQL support +installPackages+=(libmysqlclient-dev) +# PostgreSQL support +installPackages+=(libpq-dev) +# SQLite support +installPackages+=(libsqlite3-dev) +# ODBC support +installPackages+=(unixodbc-dev) +# Support for FreeType font engine +installPackages+=(libfreetype6-dev) +# Enable the usage of system jpeg libraries +installPackages+=(libjpeg-dev) +# Enable support for printer driver +installPackages+=(libcups2-dev) +# Enable support for printer test +installPackages+=(cups-pdf) +# Install libraries needed for QtMultimedia to be able to support all plugins +installPackages+=(libasound2-dev) +installPackages+=(libgstreamer1.0-dev) +installPackages+=(libgstreamer-plugins-base1.0-dev) +installPackages+=(libgstreamer-plugins-good1.0-dev) +installPackages+=(libgstreamer-plugins-bad1.0-dev) +installPackages+=(libgstreamer-gl1.0-0) +installPackages+=(gir1.2-gst-plugins-base-1.0) +installPackages+=(gir1.2-gst-plugins-bad-1.0) +installPackages+=(yasm) +installPackages+=(libva-dev) +# for QtMultimedia streaming tests +installPackages+=(vlc-bin) +installPackages+=(vlc-plugin-base) + +# Support for cross-building to x86 (needed by WebEngine boot2qt builds) +installPackages+=(g++-multilib) +# python3 development package +installPackages+=(python3-dev) +installPackages+=(python3-pip) +installPackages+=(python3-venv) +installPackages+=(virtualenv) +installPackages+=(python3-wheel) +installPackages+=(python-is-python3) +# python2 development package +installPackages+=(python2-dev) +# Automates interactive applications (Needed by RTA to automate configure testing) +installPackages+=(expect) +installPackages+=(mesa-common-dev) +installPackages+=(libgl1-mesa-glx) +installPackages+=(libgl1-mesa-dev) +installPackages+=(libegl1-mesa-dev) +installPackages+=(libegl1) +installPackages+=(libegl-mesa0) +installPackages+=(libegl-dev) +installPackages+=(libglvnd-dev) +installPackages+=(libgles2-mesa-dev) +installPackages+=(curl) +installPackages+=(libcurl4-openssl-dev) +installPackages+=(libicu-dev) +installPackages+=(zlib1g-dev) +installPackages+=(zlib1g) +installPackages+=(openjdk-8-jdk) +#Java 11 for Android +installPackages+=(openjdk-11-jdk) +installPackages+=(libgtk-3-dev) +installPackages+=(ninja-build) +installPackages+=(libssl-dev) +installPackages+=(libxcursor-dev) +installPackages+=(libxcomposite-dev) +installPackages+=(libxdamage-dev) +installPackages+=(libxrandr-dev) +installPackages+=(libfontconfig1-dev) +installPackages+=(libsrtp2-dev) +installPackages+=(libwebp-dev) +installPackages+=(libjsoncpp-dev) +installPackages+=(libopus-dev) +installPackages+=(libminizip-dev) +installPackages+=(libavutil-dev) +installPackages+=(libavformat-dev) +installPackages+=(libavcodec-dev) +installPackages+=(libevent-dev) +installPackages+=(bison) +installPackages+=(flex) +installPackages+=(gperf) +installPackages+=(libasound2-dev) +installPackages+=(libpulse-dev) +installPackages+=(libxtst-dev) +installPackages+=(libnspr4-dev) +installPackages+=(libnss3-dev) +installPackages+=(libnss3) +installPackages+=(libopenal-dev) +installPackages+=(libbluetooth-dev) +#VirtualBox for RTA +installPackages+=(virtualbox) +installPackages+=(dkms) +# Needed for qtspeech +installPackages+=(libspeechd-dev) +#Pypdf for PDF reading in RTA tests +installPackages+=(python3-pypdf2) +# Needed for b2qt +installPackages+=(git-lfs) +installPackages+=(chrpath) +installPackages+=(gawk) +installPackages+=(texinfo) +# Needed for Poppler test in QtWebEngine +installPackages+=(libpoppler-cpp-dev) +# Needed for QtCore +installPackages+=(libdouble-conversion-dev) +installPackages+=(libpcre2-dev) +# Needed for testlib selftests +installPackages+=(valgrind) +# Needed for qtgampepad +installPackages+=(libsdl2-2.0) +installPackages+=(libsdl2-dev) +# Needed for qtwebkit +installPackages+=(ruby) +installPackages+=(libxslt1-dev) +installPackages+=(libxml2-dev) +installPackages+=(libhyphen-dev) +# For remote access +installPackages+=(ssh) +# For bitbake +installPackages+=(diffstat) +installPackages+=(binfmt-support) +installPackages+=(zstd) +installPackages+=(lz4) +# Vulkan is needed for examples +installPackages+=(libvulkan-dev) +# Needed for qtdltlogging +installPackages+=(libdlt-dev) +# For integrity +installPackages+=(libc6:i386) +installPackages+=(libncurses5:i386) +installPackages+=(libstdc++6:i386) +installPackages+=(libx11-6:i386) +installPackages+=(lib32z1) +installPackages+=(linux-libc-dev:i386) +installPackages+=(libxcursor1:i386) +installPackages+=(libc6-dev-i386) +sudo dpkg --add-architecture i386 +# For QNX +installPackages+=(nfs-kernel-server) +installPackages+=(net-tools) +installPackages+=(bridge-utils) +# For Debian packaging +installPackages+=(sbuild) +installPackages+=(ubuntu-dev-tools) +# cifs-utils, for mounting smb drive +installPackages+=(keyutils) +installPackages+=(cifs-utils) +# VxWorks QEMU network setup (tunctl) +installPackages+=(uml-utilities) +# used for reading vcpkg packages version, from vcpkg.json +installPackages+=(jq) + +echo "Running update for apt" +waitLoop +sudo apt-get update +echo "Installing packages" +waitLoop +sudo DEBIAN_FRONTEND=noninteractive apt-get -q -y -o DPkg::Lock::Timeout=300 install "${installPackages[@]}" + +# Configure pip +pip config --user set global.index https://ci-files01-hki.ci.qt.io/input/python_module_cache +pip config --user set global.extra-index-url https://pypi.org/simple/ + +source "${BASH_SOURCE%/*}/../common/unix/SetEnvVar.sh" +# SetEnvVar "PATH" "/usr/lib/nodejs-mozilla/bin:\$PATH" + +OpenSSLVersion="$(openssl version |cut -b 9-14)" +echo "System's OpenSSL = $OpenSSLVersion" >> ~/versions.txt diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/02-disable-notifications.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/02-disable-notifications.sh new file mode 100755 index 00000000..1b9ed6c9 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/02-disable-notifications.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash +#Copyright (C) 2023 The Qt Company Ltd +#SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +# shellcheck source=../common/linux/disable-notifications.sh +source "${BASH_SOURCE%/*}/../common/linux/disable-notifications.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/02-disable-ntp.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/02-disable-ntp.sh new file mode 100755 index 00000000..1995aa14 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/02-disable-ntp.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash +#Copyright (C) 2023 The Qt Company Ltd +#SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +# shellcheck source=../common/linux/disable-ntp_linux.sh +source "${BASH_SOURCE%/*}/../common/linux/disable-ntp_linux.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/02-git_lfs.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/02-git_lfs.sh new file mode 100755 index 00000000..d2c0ad14 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/02-git_lfs.sh @@ -0,0 +1,12 @@ +#!/usr/bin/env bash +# Copyright (C) 2018 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +# Install Git Large File Storage + +set -ex + +curl -L https://packagecloud.io/github/git-lfs/gpgkey | sudo apt-key add - +sudo apt-add-repository 'deb https://packagecloud.io/github/git-lfs/ubuntu/ jammy main' +sudo apt update +sudo apt install git-lfs diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/02-remove-apport.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/02-remove-apport.sh new file mode 100755 index 00000000..879f3ffb --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/02-remove-apport.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash +#Copyright (C) 2023 The Qt Company Ltd +#SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +# shellcheck source=../common/linux/remove-apport.sh +source "${BASH_SOURCE%/*}/../common/linux/remove-apport.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/02-remove-update_notifier.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/02-remove-update_notifier.sh new file mode 100755 index 00000000..f4a5119f --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/02-remove-update_notifier.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash +#Copyright (C) 2023 The Qt Company Ltd +#SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +# shellcheck source=../common/linux/remove-update_notifier.sh +source "${BASH_SOURCE%/*}/../common/linux/remove-update_notifier.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/03-install-nodejs.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/03-install-nodejs.sh new file mode 100755 index 00000000..07121a36 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/03-install-nodejs.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash +# Copyright (C) 2023 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +# shellcheck source=../common/linux/install-nodejs.sh +source "${BASH_SOURCE%/*}/../common/linux/install-nodejs.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/03-mount-vcpkg-cache-drive.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/03-mount-vcpkg-cache-drive.sh new file mode 100755 index 00000000..ed49b3a5 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/03-mount-vcpkg-cache-drive.sh @@ -0,0 +1,8 @@ +#!/usr/bin/env bash +# Copyright (C) 2023 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +set -ex + +# shellcheck source=../common/linux/mount-vcpkg-cache-drive.sh +source "${BASH_SOURCE%/*}/../common/linux/mount-vcpkg-cache-drive.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/03-qemu.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/03-qemu.sh new file mode 100755 index 00000000..5ed06f29 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/03-qemu.sh @@ -0,0 +1,19 @@ +#!/usr/bin/env bash +# Copyright (C) 2021 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +set -ex + +# shellcheck source=../common/unix/SetEnvVar.sh +source "${BASH_SOURCE%/*}/../common/unix/SetEnvVar.sh" + +# First test using QFont fails if fonts-noto-cjk is installed. This happens because +# running fontcache for that font takes > 5 mins when run on QEMU. Running fc-cache +# doesn't help since host version creates cache for a wrong architecture and running +# armv7 fc-cache segfaults on QEMU. +sudo DEBIAN_FRONTEND=noninteractive apt-get -y remove fonts-noto-cjk + +# Disable QtWayland window decorations, as they cause flakiness when used inside qemu (QTBUG-66173) +qemu_env="QT_WAYLAND_DISABLE_WINDOWDECORATION=1" + +SetEnvVar "QEMU_SET_ENV" "\"${qemu_env}\"" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/04-libclang-v100-dyn.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/04-libclang-v100-dyn.sh new file mode 100755 index 00000000..85c261ee --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/04-libclang-v100-dyn.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash +#Copyright (C) 2023 The Qt Company Ltd +#SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +BASEDIR=$(dirname "$0") +"$BASEDIR/../common/unix/libclang-v100-dyn.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/04-libclang.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/04-libclang.sh new file mode 100755 index 00000000..fac8d4e7 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/04-libclang.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash +#Copyright (C) 2023 The Qt Company Ltd +#SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +BASEDIR=$(dirname "$0") +"$BASEDIR/../common/unix/libclang.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/04-yocto.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/04-yocto.sh new file mode 100755 index 00000000..a764dc7e --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/04-yocto.sh @@ -0,0 +1,126 @@ +#!/usr/bin/env bash +# Copyright (C) 2021 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +# This script installs the Yocto toolchain + +set -ex + +# shellcheck source=../common/unix/DownloadURL.sh +source "${BASH_SOURCE%/*}/../common/unix/DownloadURL.sh" +# shellcheck source=../common/unix/SetEnvVar.sh +source "${BASH_SOURCE%/*}/../common/unix/SetEnvVar.sh" + +primaryBaseUrlPath="http://ci-files01-hki.ci.qt.io/input/boot2qt/gatesgarth" +altBaseUrlPath="http://download.qt.io/development_releases/prebuilt/boot2qt/gatesgarth" + +echo "Installing Yocto toolchain for 32-bit b2qt ARMV7..." + +versionARM="3.2" +package="b2qt-x86_64-meta-toolchain-b2qt-ci-sdk-qemuarm-a9d5156a.sh" +PrimaryUrl="$primaryBaseUrlPath/$package" +AltUrl="$altBaseUrlPath/$package" +SHA1="f9f7d51656067a1cc9d7ab92ddcddb219886ab22" +yoctoInstaller="/tmp/yocto-toolchain-ARMv7.sh" +yoctoLocationARMv7="/opt/b2qt/$versionARM" +sysrootARMv7="armv7vet2hf-neon-poky-linux-gnueabi" +crosscompileARMv7="sysroots/x86_64-pokysdk-linux/usr/bin/arm-poky-linux-gnueabi/arm-poky-linux-gnueabi-" +envSetupARMv7="environment-setup-$sysrootARMv7" +toolchainFileARMv7="sysroots/x86_64-pokysdk-linux/usr/share/cmake/OEToolchainConfig.cmake" + +DownloadURL "$PrimaryUrl" "$AltUrl" "$SHA1" "$yoctoInstaller" +chmod +x "$yoctoInstaller" + +/bin/bash "$yoctoInstaller" -y -d "$yoctoLocationARMv7" +rm -rf "$yoctoInstaller" + +echo "Installing Yocto toolchain for 64-bit b2qt ARM64..." + +versionARM64="3.2" +package="b2qt-x86_64-meta-toolchain-b2qt-ci-sdk-qemuarm64-a9d5156a.sh" +PrimaryUrl="$primaryBaseUrlPath/$package" +AltUrl="$altBaseUrlPath/$package" +SHA1="f490cbcc4e0d5a87f4e07607a71013aeeabce94a" +yoctoInstaller="/tmp/yocto-toolchain-ARM64.sh" +yoctoLocationARM64="/opt/b2qt/$versionARM64" +sysrootARM64="cortexa57-poky-linux" +crosscompileARM64="sysroots/x86_64-pokysdk-linux/usr/bin/aarch64-poky-linux/aarch64-poky-linux-" +envSetupARM64="environment-setup-$sysrootARM64" +toolchainFileARM64="sysroots/x86_64-pokysdk-linux/usr/share/cmake/OEToolchainConfig.cmake" + +DownloadURL "$PrimaryUrl" "$AltUrl" "$SHA1" "$yoctoInstaller" +chmod +x "$yoctoInstaller" + +/bin/bash "$yoctoInstaller" -y -d "$yoctoLocationARM64" +rm -rf "$yoctoInstaller" + +echo "Installing Yocto toolchain for 64-bit b2qt MIPS64..." + +versionMIPS64="3.2" +package="b2qt-x86_64-meta-toolchain-b2qt-ci-sdk-qemumips64-a9d5156a.sh" +PrimaryUrl="$primaryBaseUrlPath/$package" +AltUrl="$altBaseUrlPath/$package" +SHA1="5d3a8bb4384de273937286d275d1dab36f969951" +yoctoInstaller="/tmp/yocto-toolchain-mips64.sh" +yoctoLocationMIPS64="/opt/b2qt/$versionMIPS64" +sysrootMIPS64="mips64r2-poky-linux" +crosscompileMIPS64="sysroots/x86_64-pokysdk-linux/usr/bin/mips64-poky-linux/mips64-poky-linux-" +envSetupMIPS64="environment-setup-$sysrootMIPS64" +toolchainFileMIPS64="sysroots/x86_64-pokysdk-linux/usr/share/cmake/OEToolchainConfig.cmake" + +DownloadURL "$PrimaryUrl" "$AltUrl" "$SHA1" "$yoctoInstaller" +chmod +x "$yoctoInstaller" + +/bin/bash "$yoctoInstaller" -y -d "$yoctoLocationMIPS64" +rm -rf "$yoctoInstaller" + + + +if [ -e "$yoctoLocationARMv7/sysroots/$sysrootARMv7" ] && [ -e "$yoctoLocationARMv7/${crosscompileARMv7}g++" ] && \ + [ -e "$yoctoLocationARMv7/$envSetupARMv7" ] && [ -e "$yoctoLocationARMv7/$toolchainFileARMv7" ] && \ + [ -e "$yoctoLocationARM64/sysroots/$sysrootARM64" ] && [ -e "$yoctoLocationARM64/${crosscompileARM64}g++" ] && \ + [ -e "$yoctoLocationARM64/$envSetupARM64" ] && [ -e "$yoctoLocationARM64/$toolchainFileARM64" ] && \ + [ -e "$yoctoLocationMIPS64/sysroots/$sysrootMIPS64" ] && [ -e "$yoctoLocationMIPS64/${crosscompileMIPS64}g++" ] && \ + [ -e "$yoctoLocationMIPS64/$envSetupMIPS64" ] && [ -e "$yoctoLocationMIPS64/$toolchainFileMIPS64" ]; then + SetEnvVar "QEMUARMV7_TOOLCHAIN_SYSROOT" "$yoctoLocationARMv7/sysroots/$sysrootARMv7" + SetEnvVar "QEMUARMV7_TOOLCHAIN_CROSS_COMPILE" "$yoctoLocationARMv7/$crosscompileARMv7" + SetEnvVar "QEMUARMV7_TOOLCHAIN_ENVSETUP" "$yoctoLocationARMv7/$envSetupARMv7" + SetEnvVar "QEMUARMV7_TOOLCHAIN_FILE" "$yoctoLocationARMv7/$toolchainFileARMv7" + SetEnvVar "QEMUARM64_TOOLCHAIN_SYSROOT" "$yoctoLocationARM64/sysroots/$sysrootARM64" + SetEnvVar "QEMUARM64_TOOLCHAIN_CROSS_COMPILE" "$yoctoLocationARM64/$crosscompileARM64" + SetEnvVar "QEMUARM64_TOOLCHAIN_ENVSETUP" "$yoctoLocationARM64/$envSetupARM64" + SetEnvVar "QEMUARM64_TOOLCHAIN_FILE" "$yoctoLocationARM64/$toolchainFileARM64" + SetEnvVar "QEMUMIPS64_TOOLCHAIN_SYSROOT" "$yoctoLocationMIPS64/sysroots/$sysrootMIPS64" + SetEnvVar "QEMUMIPS64_TOOLCHAIN_CROSS_COMPILE" "$yoctoLocationMIPS64/$crosscompileMIPS64" + SetEnvVar "QEMUMIPS64_TOOLCHAIN_ENVSETUP" "$yoctoLocationMIPS64/$envSetupMIPS64" + SetEnvVar "QEMUMIPS64_TOOLCHAIN_FILE" "$yoctoLocationMIPS64/$toolchainFileMIPS64" +else + echo "Error! Couldn't find installation paths for Yocto toolchain. Aborting provisioning." 1>&2 + exit 1 +fi + +cat << EOB >> ~/versions.txt +Yocto ARMv7 toolchain = $versionARM +Yocto ARM64 toolchain = $versionARM64 +Yocto MIPS64 toolchain = $versionMIPS64 +EOB + +# List qt user in qemu toolchain sysroots +sudo sh -c "grep ^qt /etc/passwd >> $yoctoLocationARMv7/sysroots/$sysrootARMv7/etc/passwd" +sudo sh -c "grep ^qt /etc/group >> $yoctoLocationARMv7/sysroots/$sysrootARMv7/etc/group" +sudo sh -c "grep ^qt /etc/passwd >> $yoctoLocationARM64/sysroots/$sysrootARM64/etc/passwd" +sudo sh -c "grep ^qt /etc/group >> $yoctoLocationARM64/sysroots/$sysrootARM64/etc/group" + +# Fix mdns to support both docker and network tests +# See also https://bugreports.qt.io/browse/QTBUG-106013 +sudo sed -i '/^hosts:/s/.*/hosts: files myhostname mdns_minimal [NOTFOUND=return] mdns4 dns/' \ + $yoctoLocationARMv7/sysroots/$sysrootARMv7/etc/nsswitch.conf \ + $yoctoLocationARM64/sysroots/$sysrootARM64/etc/nsswitch.conf + +# Install qemu binfmt for 32bit and 64bit arm architectures +sudo update-binfmts --package qemu-arm --install arm $yoctoLocationARMv7/sysroots/x86_64-pokysdk-linux/usr/bin/qemu-arm \ +--magic "\x7f\x45\x4c\x46\x01\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x28\x00" \ +--mask "\xff\xff\xff\xff\xff\xff\xff\x00\xff\xff\xff\xff\xff\xff\xff\xff\xfe\xff\xff\xff" +sudo update-binfmts --package qemu-aarch64 --install aarch64 $yoctoLocationARM64/sysroots/x86_64-pokysdk-linux/usr/bin/qemu-aarch64 \ +--magic "\x7f\x45\x4c\x46\x02\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\xb7\x00" \ +--mask "\xff\xff\xff\xff\xff\xff\xff\x00\xff\xff\xff\xff\xff\xff\xff\xff\xfe\xff\xff\xff" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/08-integrity.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/08-integrity.sh new file mode 100755 index 00000000..0e8dbb39 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/08-integrity.sh @@ -0,0 +1,8 @@ +#!/usr/bin/env bash +# Copyright (C) 2017 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +set -ex + +# shellcheck source=../common/linux/integrity.sh +source "${BASH_SOURCE%/*}/../common/linux/integrity.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/20-sccache.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/20-sccache.sh new file mode 100755 index 00000000..b371d947 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/20-sccache.sh @@ -0,0 +1,3 @@ +#!/usr/bin/env bash + +source "${BASH_SOURCE%/*}/../common/linux/sccache.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/22-mqtt_broker.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/22-mqtt_broker.sh new file mode 100755 index 00000000..b0791cb1 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/22-mqtt_broker.sh @@ -0,0 +1,8 @@ +#!/usr/bin/env bash +# Copyright (C) 2018 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +set -ex + +# shellcheck source=../common/unix/mqtt_broker.sh +source "${BASH_SOURCE%/*}/../common/unix/mqtt_broker.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/30-fbx.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/30-fbx.sh new file mode 100755 index 00000000..16a9bda8 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/30-fbx.sh @@ -0,0 +1,8 @@ +#!/usr/bin/env bash +#Copyright (C) 2023 The Qt Company Ltd +#SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +set -ex + +BASEDIR=$(dirname "$0") +"$BASEDIR/../common/linux/fbx_linux.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/30-install-conan.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/30-install-conan.sh new file mode 100755 index 00000000..c5b53fac --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/30-install-conan.sh @@ -0,0 +1,8 @@ +#!/usr/bin/env bash +#Copyright (C) 2023 The Qt Company Ltd +#SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +set -ex + +BASEDIR=$(dirname "$0") +"$BASEDIR/../common/unix/install-conan.sh" "linux" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/30-install_icu.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/30-install_icu.sh new file mode 100755 index 00000000..260dc55a --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/30-install_icu.sh @@ -0,0 +1,48 @@ +#!/usr/bin/env bash +# Copyright (C) 2023 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +# shellcheck source=../common/unix/DownloadURL.sh +source "${BASH_SOURCE%/*}/../common/unix/DownloadURL.sh" + +set -ex + +# This script will install ICU + +icuVersion="73.2" +icuLocationLib="/opt/icu/lib64" +icuLocationInclude="/opt/icu/include" +sha1="5699987afcceb0390e52fb860bb3b4ab8b39cabe" +baseBinaryPackageURL="http://ci-files01-hki.ci.qt.io/input/icu/$icuVersion/icu-linux-g++-Ubuntu22.04-x64.7z" +baseBinaryPackageExternalURL="http://master.qt.io/development_releases/prebuilt/icu/prebuilt/$icuVersion/icu-linux-g++-Ubuntu22.04-x64.7z" + +sha1Dev="6b9da2fa5fd88db88e9957ee5e3cf9dbcd08fe6b" +develPackageURL="http://ci-files01-hki.ci.qt.io/input/icu/$icuVersion/icu-linux-g++-Ubuntu22.04-x64-devel.7z" +develPackageExternalURL="http://master.qt.io/development_releases/prebuilt/icu/prebuilt/$icuVersion/icu-linux-g++-Ubuntu22.04-x64-devel.7z" + +echo "Installing custom ICU $icuVersion $sha1 packages on CentOS to $icuLocationLib" + +targetFile=$(mktemp) +sudo mkdir -p "$icuLocationLib" +sudo mkdir -p "$icuLocationInclude" +DownloadURL "$baseBinaryPackageURL" "$baseBinaryPackageExternalURL" "$sha1" "$targetFile" +sudo 7z x -y -o$icuLocationLib "$targetFile" +sudo rm "$targetFile" + +echo "Installing custom ICU devel packages on CentOS" + +tempDir=$(mktemp -d) + +targetFile=$(mktemp) +DownloadURL "$develPackageURL" "$develPackageExternalURL" "$sha1Dev" "$targetFile" +7z x -y -o"$tempDir" "$targetFile" + +sudo cp -a "$tempDir"/lib/* "$icuLocationLib" +sudo cp -a "$tempDir"/* /opt/icu/ + +sudo rm "$targetFile" +sudo rm -fr "$tempDir" + +sudo /sbin/ldconfig + +echo "ICU = $icuVersion" >> ~/versions.txt diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/35-install-breakpad.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/35-install-breakpad.sh new file mode 100755 index 00000000..8a9dde56 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/35-install-breakpad.sh @@ -0,0 +1,8 @@ +#!/usr/bin/env bash +#Copyright (C) 2023 The Qt Company Ltd +#SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +set -ex + +# shellcheck source=../common/unix/install-breakpad.sh +source "${BASH_SOURCE%/*}/../common/unix/install-breakpad.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/40-android_linux.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/40-android_linux.sh new file mode 100755 index 00000000..2526bc6d --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/40-android_linux.sh @@ -0,0 +1,8 @@ +#!/bin/bash +# Copyright (C) 2017 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +set -ex + +# shellcheck source=../common/linux/android_linux.sh +source "${BASH_SOURCE%/*}/../common/linux/android_linux.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/40-install-cmake.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/40-install-cmake.sh new file mode 100755 index 00000000..a418e4c5 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/40-install-cmake.sh @@ -0,0 +1,7 @@ +#!/bin/bash +#Copyright (C) 2023 The Qt Company Ltd +#SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +BASEDIR=$(dirname "$0") +"$BASEDIR/../common/linux/cmake_linux.sh" + diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/41-install-vcpkg.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/41-install-vcpkg.sh new file mode 100644 index 00000000..aa88364d --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/41-install-vcpkg.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash + +set -ex + +BASEDIR=$(dirname "$0") +"$BASEDIR/../common/linux/install-vcpkg.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/42-install-vcpkg-ports.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/42-install-vcpkg-ports.sh new file mode 100755 index 00000000..71a46f9a --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/42-install-vcpkg-ports.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash + +set -ex + +BASEDIR=$(dirname "$0") +"$BASEDIR/../common/linux/install-vcpkg-ports.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/45-install-cpdb.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/45-install-cpdb.sh new file mode 100755 index 00000000..40497ee0 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/45-install-cpdb.sh @@ -0,0 +1,13 @@ +#!/usr/bin/env bash +# Copyright (C) 2023 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +# This script install cpdb from sources. +# Requires GCC and Perl to be in PATH. +set -ex + +# Install the dependencies +sudo apt install -y make autoconf autopoint libglib2.0-dev libdbus-1-dev libtool + +BASEDIR=$(dirname "$0") +"$BASEDIR/../common/linux/install-cpdb.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/50-openssl_for_android_linux.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/50-openssl_for_android_linux.sh new file mode 100755 index 00000000..fd1151d9 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/50-openssl_for_android_linux.sh @@ -0,0 +1,8 @@ +#!/bin/bash +# Copyright (C) 2021 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +set -ex + +# shellcheck source=../common/unix/openssl_for_android.sh +source "${BASH_SOURCE%/*}/../common/unix/openssl_for_android.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/60-install_protobuf.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/60-install_protobuf.sh new file mode 100755 index 00000000..3e2b8921 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/60-install_protobuf.sh @@ -0,0 +1,9 @@ +#!/usr/bin/env bash +# Copyright (C) 2018 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +set -ex + +# shellcheck source=../common/unix/install_protobuf.sh +source "${BASH_SOURCE%/*}/../common/unix/install_protobuf.sh" + diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/61-install_grpc.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/61-install_grpc.sh new file mode 100755 index 00000000..ecd6a51f --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/61-install_grpc.sh @@ -0,0 +1,9 @@ +#!/usr/bin/env bash +# Copyright (C) 2022 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +set -ex + +# shellcheck source=../common/unix/install_grpc.sh +source "${BASH_SOURCE%/*}/../common/unix/install_grpc.sh" + diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/70-install_QemuGA.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/70-install_QemuGA.sh new file mode 100755 index 00000000..9a80fc0b --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/70-install_QemuGA.sh @@ -0,0 +1,10 @@ +#!/usr/bin/env bash +# Copyright (C) 2020 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +# This script installs QEMU Guest Agent + +set -ex + +sudo apt -y install qemu-guest-agent +sudo systemctl start qemu-guest-agent diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/70-qnx710.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/70-qnx710.sh new file mode 100755 index 00000000..08eeb57b --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/70-qnx710.sh @@ -0,0 +1,13 @@ +#!/usr/bin/env bash +# Copyright (C) 2021 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +set -ex + +# shellcheck source=../common/linux/qnx_710.sh +source "${BASH_SOURCE%/*}/../common/linux/qnx_710.sh" + +# setup NFS +sudo bash -c "echo '/home/qt/work ${qemuNetwork}/24(rw,sync,root_squash,no_subtree_check,anonuid=1000,anongid=1000)' >> /etc/exports" +sudo exportfs -a +sudo systemctl restart nfs-kernel-server diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/70-qnx800.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/70-qnx800.sh new file mode 100755 index 00000000..45d9e43e --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/70-qnx800.sh @@ -0,0 +1,9 @@ +#!/usr/bin/env bash +# Copyright (C) 2024 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +set -ex + +# shellcheck source=../common/linux/qnx_800.sh +source "${BASH_SOURCE%/*}/../common/linux/qnx_800.sh" + diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/70-vxworks.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/70-vxworks.sh new file mode 100755 index 00000000..3bb48d11 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/70-vxworks.sh @@ -0,0 +1,8 @@ +#!/usr/bin/env bash +# Copyright (C) 2021 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +set -ex + +# shellcheck source=../common/linux/vx_works.sh +source "${BASH_SOURCE%/*}/../common/linux/vx_works.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/80-docker.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/80-docker.sh new file mode 100755 index 00000000..3338562f --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/80-docker.sh @@ -0,0 +1,58 @@ +#!/usr/bin/env bash +# Copyright (C) 2023 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +set -e + +PROVISIONING_DIR="$(dirname "$0")/../" +# shellcheck source=../common/unix/common.sourced.sh +source "$PROVISIONING_DIR"/common/unix/common.sourced.sh +# shellcheck source=../common/unix/DownloadURL.sh +source "$PROVISIONING_DIR"/common/unix/DownloadURL.sh + +localRepo=http://ci-files01-hki.ci.qt.io/input/docker +# upstreamRepo=https://download.docker.com/linux/ubuntu/dists/bionic/pool/stable/amd64 +upstreamRepo=https://download.docker.com/linux/ubuntu/dists/jammy/pool/stable/amd64 +echo ' + 429078ba4948395ab88cd06c6ef49ea37c965273 containerd.io_1.6.4-1_amd64.deb + 5ce7508bb9d478dd9fe8ed9869e8ab0eed0355d9 docker-ce_20.10.15_3-0_ubuntu-jammy_amd64.deb + 445e81ad86c37d796de64644da4f9b3d6c6df913 docker-ce-cli_20.10.15_3-0_ubuntu-jammy_amd64.deb +' \ + | xargs -n2 | while read -r sha f +do + DownloadURL "$localRepo/$f" "$upstreamRepo/$f" "$sha" +done + +sudo apt-get -y install ./containerd.io_*.deb ./docker-ce_*.deb ./docker-ce-cli_*.deb +rm -f ./containerd.io_*.deb ./docker-ce_*.deb ./docker-ce-cli_*.deb + +sudo usermod -a -G docker "$USER" +sudo docker --version + +# Download and install the docker-compose extension from https://github.com/docker/compose/releases +f=docker-compose-$(uname -s)-$(uname -m) +DownloadURL \ + "$localRepo/$f-1.24.1" \ + "https://github.com/docker/compose/releases/download/1.24.1/$f" \ + cfb3439956216b1248308141f7193776fcf4b9c9b49cbbe2fb07885678e2bb8a +sudo install -m 755 ./docker-compose* /usr/local/bin/docker-compose +sudo docker-compose --version +rm ./docker-compose* + +# Install Avahi to discover Docker containers in the test network +sudo apt-get install avahi-daemon -y + +# Add registry mirror for docker images +sudo tee -a /etc/docker/daemon.json <<"EOF" +{ + "registry-mirrors": ["http://repo-clones.ci.qt.io:5000"] +} +EOF + +echo "Restart Docker" +sudo systemctl daemon-reload +sudo systemctl restart docker + +# Start testserver provisioning +sudo "$(readlink -f "$(dirname "${BASH_SOURCE[0]}")")/../common/shared/testserver/docker_testserver.sh" + diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/81-fix_mdns_docker_resolution.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/81-fix_mdns_docker_resolution.sh new file mode 100755 index 00000000..30fe71ca --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/81-fix_mdns_docker_resolution.sh @@ -0,0 +1,15 @@ +#!/usr/bin/env bash +# Copyright (C) 2021 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +# The new version of libnss-mdns resolver library automatically rejects all +# hostnames with more than two labels (i.e. subdomains deep), for example +# vsftpd.test-net.qt.local is automatically rejected. The changes here fix +# this, see also https://github.com/lathiat/nss-mdns#etcmdnsallow + +cat <<EOT | sudo tee /etc/mdns.allow +.local. +.local +EOT + +sudo sed -i '/^hosts:/s/.*/hosts: files mdns_minimal [NOTFOUND=return] mdns4 dns/' /etc/nsswitch.conf diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/85-qdoc_qtattributionsscanner.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/85-qdoc_qtattributionsscanner.sh new file mode 100755 index 00000000..fd2a3afd --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/85-qdoc_qtattributionsscanner.sh @@ -0,0 +1,33 @@ +#!/usr/bin/env bash +# Copyright (C) 2022 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +# Provisions qdoc and qtattributionsscanner binaries; these are used for +# documentation testing without the need for a dependency to qttools. + +set -e + +# shellcheck source=../common/unix/check_and_set_proxy.sh +"${BASH_SOURCE%/*}/../common/unix/check_and_set_proxy.sh" +# shellcheck source=../common/unix/DownloadURL.sh +source "${BASH_SOURCE%/*}/../common/unix/DownloadURL.sh" +version="68bdc5764da2d4e442181b408751b6572f36fa74" +sha1="dac76e8f6cb69990661e7d814bea6f32fea29bf4" +url="https://download.qt.io/development_releases/prebuilt/qdoc/qt/qdoc-qtattributionsscanner_${version//\./}-based-linux-Ubuntu22.04-gcc11.4-x86_64.7z" +url_cached="http://ci-files01-hki.ci.qt.io/input/qdoc/qt/qdoc-qtattributionsscanner_${version//\./}-based-linux-Ubuntu22.04-gcc11.4-x86_64.7z" + +zip="/tmp/qdoc-qtattributionsscanner.7z" +destination="/opt/qt-doctools" + +sudo mkdir -p "$destination" +sudo chmod 755 "$destination" +DownloadURL "$url_cached" "$url" "$sha1" "$zip" +if command -v 7zr &> /dev/null; then + sudo 7zr x "$zip" "-o$destination/" +else + sudo 7z x "$zip" "-o$destination/" +fi +sudo chown -R qt:users "$destination" +rm -rf "$zip" + +echo -e "qdoc = $version\nqtattributionsscanner = $version" >> ~/versions.txt diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/90-bootstrap-autostart.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/90-bootstrap-autostart.sh new file mode 100755 index 00000000..1ff43850 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/90-bootstrap-autostart.sh @@ -0,0 +1,3 @@ +#!/usr/bin/env bash + +source "${BASH_SOURCE%/*}/../common/linux/bootstrap-autostart.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/90-install-ffmpeg.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/90-install-ffmpeg.sh new file mode 100755 index 00000000..61da9b7b --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/90-install-ffmpeg.sh @@ -0,0 +1,3 @@ +#!/usr/bin/env bash + +source "${BASH_SOURCE%/*}/../common/unix/install-ffmpeg.sh" "linux" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/90-mimer.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/90-mimer.sh new file mode 100755 index 00000000..f06ca1c8 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/90-mimer.sh @@ -0,0 +1,8 @@ +#!/usr/bin/env bash +# Copyright (C) 2022 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +set -ex + +BASEDIR=$(dirname "$0") +"$BASEDIR/../common/linux/mimersql.sh" "openssl-3" "deb" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/90-squish.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/90-squish.sh new file mode 100755 index 00000000..f803ccc1 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/90-squish.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash +#Copyright (C) 2023 The Qt Company Ltd +#SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only +BASEDIR=$(dirname "$0") +"$BASEDIR/../common/unix/squishInstall.sh" + diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/91-squish-coco.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/91-squish-coco.sh new file mode 100755 index 00000000..e42a5373 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/91-squish-coco.sh @@ -0,0 +1,6 @@ +#!/bin/bash +#Copyright (C) 2023 The Qt Company Ltd +#SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +# shellcheck source=../common/linux/squish-coco.sh +source "${BASH_SOURCE%/*}/../common/linux/squish-coco.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/92-sbuild.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/92-sbuild.sh new file mode 100755 index 00000000..b178d71a --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/92-sbuild.sh @@ -0,0 +1,57 @@ +#!/usr/bin/env bash +# Copyright (C) 2021 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +# Setups sbuild environment + +tee ~/.sbuildrc << EOF +############################################################################## +# PACKAGE BUILD RELATED (additionally produce _source.changes) +############################################################################## +# -d +\$distribution = 'stable'; +# -A +\$build_arch_all = 1; +# -s +\$build_source = 1; +# -v +\$verbose = 1; +# parallel build +\$ENV{'DEB_BUILD_OPTIONS'} = 'parallel=8'; +############################################################################## +# POST-BUILD RELATED (turn off functionality by setting variables to 0) +############################################################################## +\$run_lintian = 1; +\$lintian_opts = ['-i', '-I']; +\$run_piuparts = 0; +\$piuparts_opts = ['--schroot', 'stable-amd64-sbuild', '--no-eatmydata']; +\$run_autopkgtest = 0; +\$autopkgtest_root_args = ''; +\$autopkgtest_opts = [ '--', 'schroot', '%r-%a-sbuild' ]; + +############################################################################## +# PERL MAGIC +############################################################################## +1; +EOF + +# Add user group +sudo sbuild-adduser "$LOGNAME" +newgrp sbuild + +# Create chroot +sudo sbuild-createchroot --include=eatmydata,ccache,gnupg,ca-certificates stable /srv/chroot/stable-amd64 + +# For ubuntu 22.04 +echo "Create chroot for Ubuntu Jammy" +## ccache can't be found with Jammy +sudo sbuild-createchroot --include=eatmydata,gnupg,ca-certificates jammy /srv/chroot/jammy-amd64 http://archive.ubuntu.com/ubuntu/ +echo "Done creating chroot for Ubuntu Jammy" + +# Update chroot. +sudo sbuild-update -udcar stable + + + + + diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/93-axivion-bauhaus-suite.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/93-axivion-bauhaus-suite.sh new file mode 100755 index 00000000..8cecbbc3 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/93-axivion-bauhaus-suite.sh @@ -0,0 +1,6 @@ +#!/bin/bash +#Copyright (C) 2023 The Qt Company Ltd +#SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +# shellcheck source=../common/linux/axivion-bauhaus-suite.sh +source "${BASH_SOURCE%/*}/../common/linux/axivion-bauhaus-suite.sh" diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/93-download-files-for-sbuild.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/93-download-files-for-sbuild.sh new file mode 100755 index 00000000..8b8530a3 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/93-download-files-for-sbuild.sh @@ -0,0 +1,16 @@ +#!/usr/bin/env bash +# Copyright (C) 2023 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +# Get required deb files for sbuild to build qt debian packages for Ubuntu jammy +mkdir -p /home/qt/debian_packages +cd /home/qt/debian_packages || exit +# Backported cmake 3.24 +wget https://ci-files01-hki.intra.qt.io/input/debian/cmake/amd64-jammy/cmake-3.24-deb.tar.gz +tar xzf cmake-3.24-deb.tar.gz +rm -rf cmake-3.24-deb.tar.gz +# get rest of ready made Ubuntu jammy arm debian packages +# so that sbuild can find those + +wget http://ci-files01-hki.ci.qt.io/input/debian/icu/amd64-jammy/libicu-56.1-qt_56.1-1_amd64.deb +wget http://ci-files01-hki.ci.qt.io/input/debian/icu/amd64-jammy/libicu-56.1-qt-dev_56.1-1_amd64.deb diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/93-lcov.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/93-lcov.sh new file mode 100755 index 00000000..de4a74d5 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/93-lcov.sh @@ -0,0 +1,9 @@ +#!/usr/bin/env bash +# Copyright (C) 2024 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +# Install lcov 2.0 from 24.04/noble numbat + +echo "Installing lcov" +wget https://ci-files01-hki.ci.qt.io/input/lcov/lcov_2.0-4ubuntu1_all.deb +sudo DEBIAN_FRONTEND=noninteractive apt-get -q -y -o DPkg::Lock::Timeout=300 install -f ./lcov_2.0-4ubuntu1_all.deb diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/99-cleanup.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/99-cleanup.sh new file mode 100755 index 00000000..4d6e16ea --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/99-cleanup.sh @@ -0,0 +1,7 @@ +#!/usr/bin/env bash +# Copyright (C) 2022 The Qt Company Ltd. +# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +set -ex + +"$(dirname "$0")"/../common/linux/cleanup_cache.sh diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/99-enable_test_stacktraces.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/99-enable_test_stacktraces.sh new file mode 100755 index 00000000..600b7850 --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/99-enable_test_stacktraces.sh @@ -0,0 +1,8 @@ +#!/usr/bin/env bash +#Copyright (C) 2023 The Qt Company Ltd +#SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +set -ex + +BASEDIR=$(dirname "$0") +"$BASEDIR"/../common/linux/enable_test_stacktraces.sh diff --git a/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/99-version.sh b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/99-version.sh new file mode 100755 index 00000000..31821f6b --- /dev/null +++ b/coin/provisioning/qtci-linux-Ubuntu-22.04-x86_64/99-version.sh @@ -0,0 +1,6 @@ +#!/bin/bash +#Copyright (C) 2023 The Qt Company Ltd +#SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only + +BASEDIR=$(dirname "$0") +"$BASEDIR/../common/linux/ubuntu-version.sh" |