#!/usr/bin/make -f export DEB_BUILD_MAINT_OPTIONS = hardening=+all export DEB_LDFLAGS_MAINT_APPEND = -Wl,-O1 %: dh $@ override_dh_autoreconf: dh_autoreconf --as-needed CONFFLAGS = \ -Dprofiler=false \ -Dremote_desktop=false \ -Dtests=true \ -Dcore_tests=false ifeq ($(DEB_HOST_ARCH_OS),linux) CONFFLAGS += \ -Degl_device=true\ -Dwayland=true \ -Dwayland_eglstream=true \ -Dnative_backend=true else CONFFLAGS += \ -Dudev=false \ -Dcore_tests=false \ -Dlibwacom=false \ -Dwayland=false \ -Dnative_backend=false endif ifeq ($(DEB_HOST_ARCH),$(findstring $(DEB_HOST_ARCH),armel armhf)) CONFFLAGS += \ -Ddefault_driver=gles2 else CONFFLAGS += \ -Ddefault_driver=gl endif override_dh_auto_configure: dh_auto_configure -- \ $(CONFFLAGS) # Use meson test directly as it allows us to use the timeout multiplier BUILDDIR=$(CURDIR)/obj-$(DEB_HOST_GNU_TYPE) TEST_COMMAND_BASE=env \ -u XDG_CACHE_HOME \ -u XDG_CONFIG_DIRS \ -u XDG_CONFIG_HOME \ -u XDG_DATA_DIRS \ -u XDG_DATA_HOME \ HOME=$(BUILDDIR)/HOME \ XDG_RUNTIME_DIR=$(BUILDDIR)/XRD \ GIO_USE_VFS=local \ GIO_USE_VOLUME_MONITOR=unix \ GSETTINGS_SCHEMA_DIR=$(BUILDDIR)/data \ GVFS_DISABLE_FUSE=1 \ dbus-run-session -- \ xvfb-run -s '+iglx -noreset -screen 0 1280x1024x24' -a \ meson test -C $(BUILDDIR) --no-rebuild --verbose --timeout-multiplier 6 \ --no-stdsplit --print-errorlogs TEST_COMMAND=$(TEST_COMMAND_BASE) --no-suite flaky TEST_COMMAND_FLAKY=$(TEST_COMMAND_BASE) --suite flaky # Ignore test failures on hurd, kfreebsd and s390x. Although the test results # indicate there may be a serious issue, the port maintainers may # prefer we do the build anyway. I plan to file a bug for this later. # Don't run the tests on mips and other ports since they either # time out or fail too much, blocking migration to testing or ports override_dh_auto_test: debian/tests/ensure-x11-dir ifeq (,$(filter nocheck, $(DEB_BUILD_OPTIONS))) glib-compile-schemas $(BUILDDIR)/data mkdir -m 700 $(BUILDDIR)/HOME mkdir -m 700 $(BUILDDIR)/XRD ifneq (,$(filter hurd-i386 kfreebsd-i386 kfreebsd-amd64 riscv64 s390x,$(DEB_HOST_ARCH))) -$(TEST_COMMAND) -$(TEST_COMMAND_FLAKY) --logbase flaky-tests else ifeq (,$(filter mips mips64el mipsel alpha hppa powerpc sparc64 x32,$(DEB_HOST_ARCH))) $(TEST_COMMAND) -$(TEST_COMMAND_FLAKY) --logbase flaky-tests endif endif override_dh_missing: dh_missing --fail-missing override_dh_girepository: dh_girepository /usr/lib/$(DEB_HOST_MULTIARCH)/muffin override_dh_makeshlibs: dh_makeshlibs -V override_dh_shlibdeps: dh_shlibdeps -Llibmuffin-0 -l/usr/lib/$(DEB_HOST_MULTIARCH)/muffin