blob: 090da6cd35f57d590f8d94bd7b10cdb1923d655c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
|
#!/usr/bin/make -f
DEB_PYTHON_SYSTEM = pysupport
DEB_PYTHON_CLEAN_ARGS = --all
include /usr/share/cdbs/1/rules/debhelper.mk
include /usr/share/cdbs/1/class/python-distutils.mk
COMMANDS = git-buildpackage \
git-import-dsc \
git-import-dscs \
git-import-orig \
git-dch \
gbp-pull \
gbp-clone
EXAMPLE_SCRIPTS=\
gbp-add-patch \
gbp-cowbuilder-sid \
gbp-pbuilder \
gbp-posttag-push \
gbp-create-remote-repo
DEB_COMPRESS_EXCLUDE=$(EXAMPLE_SCRIPTS)
SGML_MANPAGES=$(patsubst %,docs/%.1,$(COMMANDS) gbp-pq)
POD_MANPAGES=docs/git-pbuilder.1
MANPAGES=$(SGML_MANPAGES) $(POD_MANPAGES)
MANUAL=docs/manual-html
PYCHECKS=$(patsubst %,%.py,$(COMMANDS))
PYCHECK_LEVEL=Error
GBP_VERSION=gbp/gbp_version.py
VERSION_ENT=docs/version.ent
docs/%.1: docs/man.%.sgml
docbook2man -o docs/ $<
docs/manual.sgml: docs/version.ent
$(MANUAL): docs/manual.sgml docs/chapters/*.sgml docs/manpages/*.sgml
docbook-2-html -s local $<
cp /usr/share/gtk-doc/data/*.png $(MANUAL)
docs/git-pbuilder.1: git-pbuilder
pod2man $< $@
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
checks: $(PYCHECKS)
nosetests --with-doctest
endif
%.py: %
ln -s $< $@
PYTHONPATH=. pychecker -e $(PYCHECK_LEVEL) -q $<
$(GBP_VERSION): debian/changelog
echo 'gbp_version="$(DEB_VERSION)"' > $(GBP_VERSION)
$(VERSION_ENT): debian/changelog
echo '<!ENTITY gbp-version "$(DEB_VERSION)">' > $(VERSION_ENT)
build/git-buildpackage:: $(MANPAGES) $(MANUAL) $(GBP_VERSION) checks
binary-post-install/git-buildpackage::
dh_bash-completion
clean::
-rm git-*.py gbp-*.py
-rm docs/*.1 docs/manpage.* $(VERSION_ENT) git-pbuilder.1
-rm -r docs/manual-html/
.PHONY: checks
|