#!/usr/bin/make -f export DEB_BUILD_MAINT_OPTIONS = hardening=+all include /usr/share/dpkg/buildopts.mk TEST_FILTER = ~[.] TEST_GUI_FILTER = ~[.] ifneq (,$(filter $(DEB_HOST_ARCH), alpha hppa loong64 mips64el riscv64 s390x)) TEST_FILTER += ~[special-file] endif ifneq (,$(filter $(DEB_HOST_ARCH), alpha hppa loong64 mips64el ppc64 riscv64 s390x sparc64 x32)) TEST_GUI_FILTER += ~WebView endif ifneq (,$(filter $(DEB_HOST_ARCH), i386)) TEST_GUI_FILTER += ~wxImage::ChangeColours endif # These are failing intermittently (font size related?) TEST_GUI_FILTER += ~wxDC::GetPartialTextExtent ~TextCtrlTestCase %: dh $@ override_dh_autoreconf: override_dh_auto_configure: dh_auto_configure -- \ GREP=/bin/grep \ --disable-glcanvasegl \ --with-liblzma \ --enable-repro-build override_dh_auto_install: dh_auto_install sed "s/@DEB_HOST_MULTIARCH@/$(DEB_HOST_MULTIARCH)/g" debian/libwxgtk3.2-dev.alternatives.in > debian/libwxgtk3.2-dev.alternatives mv debian/tmp/usr/bin/wxrc-3.2 debian/tmp/usr/bin/wxrc override_dh_install: dh_install rm -f debian/libwxgtk3.2-1t64/usr/lib/*/libwx_gtk*gl*.so.* rm -f debian/libwxgtk3.2-1t64/usr/lib/*/libwx_gtk*media*.so.* rm -f debian/libwxgtk3.2-1t64/usr/lib/*/libwx_gtk*webview*.so.* rm -f debian/libwxgtk3.2-dev/usr/lib/*/libwx_gtk*media*.so rm -f debian/libwxgtk3.2-dev/usr/lib/*/libwx_gtk*webview*.so override_dh_installdocs-indep: WX_SKIP_DOXYGEN_VERSION_CHECK=1 docs/doxygen/regen.sh html dh_installdocs find debian/wx3.2-doc \( -name '*.dot' -o -name '*.md5' \) -delete override_dh_installexamples-indep: dh_installexamples for f in `find debian/wx3.2-examples -name makefile.unx` ; do \ mv $$f `dirname $$f`/Makefile ; \ done # don't install files from the examples which are only useful on other # platforms (the "horse*" files are a special case, as the image sample # uses various foreign image formats as data). find debian/wx3.2-examples \( \ -name 'Makefile.in' -o \ -name 'Info*.plist*' -o \ -name 'makefile.*' -o \ -name '*.bat' -o \ -name '*.bdsproj' -o \ -name '*.cur' -o \ -name '*.dsp' -o \ -name '*.dsw' -o \ -name '*.icc' -o \ -name '*.icns' -o \ -name '*.ico' -o \ -name '*.mms' -o \ -name '*.pbxproj' -o \ -name '*.plc' -o \ -name '*.r' -o \ -name '*.rc' -o \ -name '*.rc?' -o \ -name '*.vcproj' \ \) \! -name 'horse*' -delete # We end up with some empty directories which only had OS X build stuff # in, at least in 3.0.2. find debian/wx3.2-examples -type d -empty -delete override_dh_auto_test: HOME=$(CURDIR)/debian/.debhelper/generated/_source/home override_dh_auto_test: make -j$(DEB_BUILD_OPTION_PARALLEL) -C tests ifneq (,$(filter $(DEB_HOST_ARCH), hppa sh4 x32)) cd tests && WX_TEST_WEBREQUEST_URL=0 ./test $(TEST_FILTER) else python3 -m httpbin.core & export HTTPBIN_PID=$$!; RC=0; cd tests && WX_TEST_WEBREQUEST_URL="http://localhost:5000" ./test $(TEST_FILTER) || RC=1; kill -9 $${HTTPBIN_PID}; exit $$RC endif cd tests && wxUSE_XVFB=1 xvfb-run -a ./test_gui $(TEST_GUI_FILTER) override_dh_auto_clean: dh_auto_clean [ -f tests/Makefile ] && make -j$(DEB_BUILD_OPTION_PARALLEL) -C tests distclean || true find demos -name Makefile -delete find samples -name Makefile -delete find tests -name Makefile -delete find utils -name Makefile -delete