On Fri, Feb 12, 2010, Rocky Bernstein wrote: > Therefore what I suggest is do some sort of test to see if there's an > interactive tty and if not skip all of the tests. Or unconditionally skip > all tests when building on Debian for packaging.
I think that's fair; let's make the Debian packaging only run make check if /dev/tty exists. @Clint: would the attached patch be ok with you? I fixed some other small things with respect to double builds and the like. (I noticed some additional issues such as the testsuite not working under my locale -- fr_FR.UTF-8 -- and some files getting cleaned by the upstream distclean which are in the tarball and wont be present in the second build, but didn't research these) Thanks, -- Loïc Minier
diff -u zshdb-0.03+git20090920/debian/control zshdb-0.03+git20090920/debian/control --- zshdb-0.03+git20090920/debian/control +++ zshdb-0.03+git20090920/debian/control @@ -2,7 +2,7 @@ Section: devel Priority: extra Maintainer: Clint Adams <sch...@debian.org> -Build-Depends: zsh (>= 4.3.9), emacs23 +Build-Depends: zsh (>= 4.3.9), emacs23, procps Standards-Version: 3.8.3 Vcs-Git: git://git.debian.org/git/private/schizo/zshdb.git Vcs-Browser: http://git.debian.org/?p=private/schizo/zshdb.git diff -u zshdb-0.03+git20090920/debian/changelog zshdb-0.03+git20090920/debian/changelog --- zshdb-0.03+git20090920/debian/changelog +++ zshdb-0.03+git20090920/debian/changelog @@ -1,3 +1,23 @@ +zshdb (0.03+git20090920-1ubuntu2) lucid; urgency=low + + * Revise tty check to use "tty" instead of just checking for the presence of + /dev/tty. + * Clean debian/files. + * Clean doc/zshdb.1 and test/lopts.check which are not cleaned up by the + upstream build. + + -- Loïc Minier <loic.min...@ubuntu.com> Fri, 12 Feb 2010 23:41:16 +0100 + +zshdb (0.03+git20090920-1ubuntu1) lucid; urgency=low + + * Add procps build-dep to allow the testsuite to call "ps" in + test/zsh/ok4zshdb.sh:get_processor(). + * Only run testsuite if /dev/tty exists and nocheck isn't in + DEB_BUILD_OPTIONS; closes: #560665. + * Split make check in its own check target. + + -- Loïc Minier <loic.min...@ubuntu.com> Fri, 12 Feb 2010 23:02:00 +0100 + zshdb (0.03+git20090920-1) unstable; urgency=low * New upstream snapshot. diff -u zshdb-0.03+git20090920/debian/rules zshdb-0.03+git20090920/debian/rules --- zshdb-0.03+git20090920/debian/rules +++ zshdb-0.03+git20090920/debian/rules @@ -27,10 +27,14 @@ # cd obj && $(MAKE) # cd obj && $(MAKE) check $(MAKE) - $(MAKE) check touch $@ +check: build + if tty >/dev/null 2>&1; then $(MAKE) check; else echo "*** NOT RUNNING TESTSUITE WITHOUT A TTY ***" >&2; fi + +maybe_check = $(if $(findstring nocheck,$(DEB_BUILD_OPTIONS)),,check) + clean: checkroot test ! -f Makefile || $(MAKE) distclean rm -rf obj autom4te.cache @@ -38,6 +42,8 @@ rm -f debian/zshdb.substvars *~ *-stamp rm -rf debian/zshdb/ + rm -f debian/files + rm -f doc/zshdb.1 test/lopts.check install: build checkroot rm -rf debian/zshdb @@ -46,8 +52,7 @@ # cd obj && $(MAKE) DESTDIR=$(CURDIR)/debian/zshdb install $(MAKE) DESTDIR=$(CURDIR)/debian/zshdb install - -binary-indep: build install checkroot +binary-indep: build $(maybe_check) install checkroot rm -f debian/zshdb/usr/share/emacs/site-lisp/zshdb/zshdb.elc $(INSTALL_DIR) debian/zshdb/usr/share/doc/zshdb $(INSTALL_FILE) debian/changelog debian/zshdb/usr/share/doc/zshdb/changelog.Debian @@ -94 +99 @@ -.PHONY: build clean binary-indep binary-arch binary install configure prebuild +.PHONY: build check clean binary-indep binary-arch binary install configure prebuild