From 1ceac8a8d744a661b79e3030c031a55c03804b56 Mon Sep 17 00:00:00 2001 From: Lieven Hey Date: Tue, 16 Jan 2024 11:58:33 +0100 Subject: [PATCH] add ci test for non optional build This commit adds a ci build to build hotspot without optional dependencies. This should prevents bugs like #575 (fails to build without qcustomplot). --- .github/workflows/compile-and-test.yml | 23 +++++++++++++++++++ .../compile-test/BaseArchlinuxWithoutOptional | 10 ++++++++ scripts/compile-test/build.sh | 1 + scripts/compile-test/push.sh | 1 + 4 files changed, 35 insertions(+) create mode 100644 scripts/compile-test/BaseArchlinuxWithoutOptional diff --git a/.github/workflows/compile-and-test.yml b/.github/workflows/compile-and-test.yml index e429eb381..4fdfb4c2a 100644 --- a/.github/workflows/compile-and-test.yml +++ b/.github/workflows/compile-and-test.yml @@ -137,6 +137,29 @@ jobs: name: clang-tidy-fixits path: scripts/fixits/fixits.yaml + archlinux-without-optional: + needs: pre_job + if: ${{ needs.pre_job.outputs.should_skip != 'true' }} + + runs-on: ubuntu-latest + container: ghcr.io/kdab/hotspot-archlinuxwithoutoptional-dependencies + + steps: + - name: Checkout + uses: actions/checkout@v3 + with: + submodules: recursive + + - name: Configure + run: cmake --preset dev-asan + -DCMAKE_CXX_FLAGS_INIT=-Werror -DCMAKE_C_FLAGS_INIT=-Werror + + - name: Build + run: cmake --build --preset dev-asan + + - name: Test + run: ctest --preset dev-asan + fedora34: needs: pre_job if: ${{ needs.pre_job.outputs.should_skip != 'true' }} diff --git a/scripts/compile-test/BaseArchlinuxWithoutOptional b/scripts/compile-test/BaseArchlinuxWithoutOptional new file mode 100644 index 000000000..27cc36659 --- /dev/null +++ b/scripts/compile-test/BaseArchlinuxWithoutOptional @@ -0,0 +1,10 @@ +FROM archlinux:latest + +# install dependencies + +RUN pacman -Sy --noconfirm && \ + pacman -S archlinux-keyring --noconfirm && pacman-key --init && pacman-key --populate && \ + pacman -Syu --noconfirm git make qt5-x11extras cmake gcc extra-cmake-modules \ + libelf gettext qt5-base ninja \ + threadweaver5 kconfigwidgets5 knotifications5 \ + kiconthemes5 kitemviews5 kitemmodels5 kwindowsystem5 kio5 kparts5 solid5 clazy python python-yaml diff --git a/scripts/compile-test/build.sh b/scripts/compile-test/build.sh index 279df9eb8..2cb488ea5 100755 --- a/scripts/compile-test/build.sh +++ b/scripts/compile-test/build.sh @@ -72,6 +72,7 @@ export DOCKER_BUILDKIT=1 buildHotspotWithoutPresets Ubuntu20.04 1.6 buildHotspotWithPresets Ubuntu22.04 2.0 buildHotspotWithPresets Archlinux 2.0 +buildHotspotWithPresets ArchlinuxWithoutOptional 2.0 buildHotspotWithPresets OpenSuseTumbleweed 2.0 buildHotspotWithoutPresets Fedora34 2.0 buildHotspotWithPresets NeonQt6 2.0 diff --git a/scripts/compile-test/push.sh b/scripts/compile-test/push.sh index 4bf919066..b92f200bd 100755 --- a/scripts/compile-test/push.sh +++ b/scripts/compile-test/push.sh @@ -21,6 +21,7 @@ pushDependencies() pushDependencies ubuntu20.04 pushDependencies ubuntu22.04 pushDependencies archlinux +pushDependencies archlinuxwithoutoptional pushDependencies opensusetumbleweed pushDependencies fedora34 pushDependencies neonqt6