| 1 |
#!/usr/bin/make -f |
| 2 |
|
| 3 |
export DEB_BUILD_MAINT_OPTIONS = hardening=+all |
| 4 |
export DEB_LDFLAGS_MAINT_APPEND = -Wl,-O1 |
| 5 |
binaries := $(shell dh_listpackages) |
| 6 |
|
| 7 |
CONFFLAGS = |
| 8 |
BACKENDS = x11 \ |
| 9 |
gdk \ |
| 10 |
eglnative |
| 11 |
|
| 12 |
ifeq ($(DEB_HOST_ARCH_OS),linux) |
| 13 |
CONFFLAGS += -Dwayland_compositor=true |
| 14 |
BACKENDS += wayland |
| 15 |
endif |
| 16 |
|
| 17 |
ifeq (,$(filter %-doc,$(binaries))) |
| 18 |
CONFFLAGS += -Ddocumentation=false |
| 19 |
endif |
| 20 |
|
| 21 |
comma:= , |
| 22 |
empty:= |
| 23 |
space:= $(empty) $(empty) |
| 24 |
|
| 25 |
%: |
| 26 |
dh $@ --buildsystem=meson --without autoreconf |
| 27 |
|
| 28 |
override_dh_auto_configure: |
| 29 |
dh_auto_configure -- \ |
| 30 |
-Dbackends=$(subst $(space),$(comma),$(BACKENDS)) \ |
| 31 |
$(CONFFLAGS) |
| 32 |
|
| 33 |
# debhelper >= 13.4 makes all of /usr/libexec executable, which is not |
| 34 |
# quite right for installed-tests |
| 35 |
override_dh_fixperms: |
| 36 |
dh_fixperms -Xusr/libexec/installed-tests |
| 37 |
ifneq ($(filter %-tests,$(binaries)),) |
| 38 |
chmod --recursive --changes a+rX,u+w,og-w debian/*-tests/usr/libexec/installed-tests |
| 39 |
endif |
| 40 |
|
| 41 |
override_dh_compress: |
| 42 |
dh_compress -X.c |
| 43 |
|
| 44 |
override_dh_gnome: |
| 45 |
dh_gnome --no-gnome-versions |
| 46 |
|
| 47 |
override_dh_makeshlibs: |
| 48 |
dh_makeshlibs -V -- -c4 |
| 49 |
|
| 50 |
override_dh_auto_test: |
| 51 |
# Don't run the tests on s390x since it hangs the build on Launchpad |
| 52 |
# Don't run on armel since it hung with |
| 53 |
# https://buildd.debian.org/status/logs.php?pkg=clutter-1.0&ver=1.26.2%2Bdfsg-5 |
| 54 |
ifneq (,$(filter armel s390x,$(DEB_HOST_ARCH))) |
| 55 |
# Ignore test failures on architectures where they fail |
| 56 |
else ifneq (,$(filter hppa hurd-i386 kfreebsd-i386 kfreebsd-amd64 mips mipsel mips64el powerpc ppc64 sparc64,$(DEB_HOST_ARCH))) |
| 57 |
-dbus-run-session -- xvfb-run -a dh_auto_test -- --timeout-multiplier 3 |
| 58 |
else |
| 59 |
dbus-run-session -- xvfb-run -a dh_auto_test -- --timeout-multiplier 3 |
| 60 |
endif |
| 61 |
|
| 62 |
override_dh_gnome_clean: |