Fix handling of DEB_BUILD_OPTIONS=nocheck

Run tests when nocheck is not set in DEB_BUILD_OPTIONS and skip
tests and building tests when nocheck is set.

Also make the check's style in sync with the official Debian package.
This commit is contained in:
Balint Reczey 2022-07-21 09:48:55 +02:00 committed by Gerald Combs
parent 5991a75d78
commit 18b0c379a3
1 changed files with 2 additions and 3 deletions

View File

@ -44,7 +44,7 @@ override_dh_auto_build:
$(MAKE) -C $(CURDIR)/obj-* user_guide_html developer_guide_html
# fix links in documentation
sed -i "s|$(CURDIR)/docbook|..|" obj-*/docbook/ws*g_html_chunked/*.html
ifneq ($(filter $(DEB_BUILD_OPTIONS),nocheck),)
ifeq (,$(filter $(DEB_BUILD_OPTIONS),nocheck))
# Required for the "unittests" suite.
$(MAKE) -C $(CURDIR)/obj-* test-programs
endif
@ -78,9 +78,8 @@ override_dh_fixperms:
debian/wireshark-dev/usr/share/pyshared/wireshark_be.py \
debian/wireshark-dev/usr/share/pyshared/wireshark_gen.py
# Adapted from https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=861988
override_dh_auto_test:
ifneq ($(filter $(DEB_BUILD_OPTIONS),nocheck),)
ifeq (,$(filter $(DEB_BUILD_OPTIONS),nocheck))
# XXX Add -- --verbose?
dh_auto_test
else