@@ -7,6 +7,12 @@ include /usr/share/dpkg/default.mk
77#export DH_VERBOSE=1
88export DPKG_GENSYMBOLS_CHECK_LEVEL=4
99export NO_PNG_PKG_MANGLE=1
10+export QT_SELECT=qt5
11+
12+DEB_HOST_ARCH ?= $(shell dpkg-architecture -qDEB_HOST_ARCH)
13+
14+# Skip tests on the archs they are known to be flaky with current configuration
15+testskip_architectures := powerpc ppc64el s390x
1016
1117%:
1218 dh $@ --parallel --fail-missing --with python3
@@ -24,7 +30,13 @@ override_dh_auto_test:
2430 # Run the entire test battery
2531 # Parallel tests have a risk of starting xvfb on the same DISPLAY multiple times,
2632 # causing the whole battery to fail.
27− dh_auto_test --no-parallel -- -O -k xvfballtests || true
33+ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
34+ifneq (,$(filter $(DEB_HOST_ARCH),$(testskip_architectures)))
35+ -dh_auto_test --no-parallel -- -O -k xvfballtests
36+else
37+ dh_auto_test --no-parallel -- -O -k xvfballtests
38+endif
39+endif
2840
2941override_dh_install:
3042 # install autopilot tests