File: rules

package info (click to toggle)
python-gendoc 0.73-8
  • links: PTS
  • area: main
  • in suites: woody
  • size: 312 kB
  • ctags: 845
  • sloc: python: 2,610; makefile: 124; sh: 26
file content (64 lines) | stat: -rwxr-xr-x 1,577 bytes parent folder | download | duplicates (2)
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
#! /usr/bin/make -f
# Made with the aid of debmake, by Christoph Lameter,
# based on the sample debian/rules file for GNU hello by Ian Jackson.

export SHELL = /bin/bash

package	  =  python-gendoc
pyversion := $(shell /usr/bin/python -c 'import sys; print sys.version[:3]')
pysitedir =  usr/lib/python$(pyversion)/site-packages
i	  := $(shell pwd)/debian/tmp

build:
	dh_testdir
	touch build

clean:
	dh_testdir
	-rm -f build
	-find . -name '*.py[co]' | xargs rm -f
	-rm -rf $(i) debian/files* core debian/substvars
	dh_clean

instdirs = \
	usr/bin \
	usr/share/man/man1 \
	$(pysitedir)/gendoc/formatters \
	usr/share/doc/$(package)

binary-indep: build
	dh_testdir
	dh_testroot
	dh_clean -k
	dh_installdirs $(instdirs)

	$(MAKE) install PYTHON_BIN=$(i)/usr/bin \
		PYTHON_LIB=$(i)/$(pysitedir)
#	install -m 644 rand.py $(i)/$(pysitedir)/
	install -m 644 debian/gendoc.1 $(i)/usr/share/man/man1/
	chmod a+x $(i)/$(pysitedir)/gendoc/{StructuredText.py,gendoc.py}

	dh_installdocs ANNOUNCE.docco README README.docco TODO gendoc_test.py
	dh_installchangelogs
#	dh_installmanpages
	-find $(i) -name '*.py[co]' | xargs rm -f
#	install -m 644 debian/doc-base $(i)/usr/share/doc-base/$(package)
	dh_fixperms
	dh_compress -X.py -X.jpg -X.gif
	dh_installdeb
	dh_gencontrol
	dh_md5sums
	dh_builddeb

binary-arch: build
	dh_testdir
# There are no architecture-dependent files to be uploaded
# generated by this package.  If there were any they would be
# made here.


# Below here is fairly generic really

binary:	binary-indep binary-arch

.PHONY: binary binary-arch binary-indep clean