summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGuido Günther <agx@sigxcpu.org>2011-03-19 16:56:25 +0100
committerGuido Günther <agx@sigxcpu.org>2011-03-19 16:56:25 +0100
commit7e0a3ade885735cbb34c0f5f7967759fcaba8f62 (patch)
tree9aa1d260b863d8b9e08e8fa61e1a488b6b0e151a
parent6f00f12fbb2f89aca71c06f08b2cb92bd259102a (diff)
rules: change symlink rule to use underscores
so we can use the gbp commands in nosetests
-rwxr-xr-xdebian/rules13
1 files changed, 10 insertions, 3 deletions
diff --git a/debian/rules b/debian/rules
index cf25ba73..b3ecc319 100755
--- a/debian/rules
+++ b/debian/rules
@@ -29,7 +29,6 @@ SGML_MANPAGES=$(patsubst %,docs/%.1,$(COMMANDS))
POD_MANPAGES=docs/git-pbuilder.1
MANPAGES=$(SGML_MANPAGES) $(POD_MANPAGES)
MANUAL=docs/manual-html
-PYCHECKS=$(patsubst %,%.py,$(COMMANDS))
PYCHECKER_ARGS=--maxlines=200 -boptparse --no-override --no-shadowbuiltin
GBP_VERSION=gbp/gbp_version.py
VERSION_ENT=docs/version.ent
@@ -47,7 +46,15 @@ docs/git-pbuilder.1: git-pbuilder
pod2man $< $@
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
-checks: $(PYCHECKS)
+
+links_stamp:
+ for c in $(COMMANDS); do \
+ ln -s $$c $$(echo $$c | sed -e 's,-,_,g').py; \
+ done
+ touch links_stamp
+
+
+checks: links_stamp
nosetests --with-doctest
endif
@@ -67,7 +74,7 @@ binary-post-install/git-buildpackage::
dh_bash-completion
clean::
- -rm git-*.py gbp-*.py gbp/gbp_version.py
+ -rm git_*.py gbp_*.py gbp/gbp_version.py links_stamp
-rm docs/*.1 docs/manpage.* $(VERSION_ENT) git-pbuilder.1
-rm -r docs/manual-html/