3 # Uncomment this to turn on verbose mode.
6 PYTHON_VERSION=$(shell /usr/bin/python -V 2>&1 | /usr/bin/perl -le 'print "$$1.$$2" if <> =~m/^Python\s+(\d+)\.(\d+)(\.\d+)*/')
8 build: build-arch build-indep
9 build-arch: build-stamp
10 build-indep: build-stamp
12 build-stamp: apt-p2p.8 apt-p2p.conf.5
16 %.5 %.8: debian/%.sgml
17 /usr/bin/docbook-to-man $< > debian/$@
22 rm -rf build/ apt_p2p/*.pyc apt_p2p_Khashmir/*.pyc *.pyc
35 ./setup.py install --prefix=$(CURDIR)/debian/apt-p2p/usr \
36 --install-lib=$(CURDIR)/debian/apt-p2p/usr/share/python-support/apt-p2p \
37 --install-scripts=$(CURDIR)/debian/apt-p2p/usr/sbin
39 # Remove the generated .pyc files
40 ( cd debian/apt-p2p/usr/share/python-support/apt-p2p/apt_p2p_Khashmir && \
45 # Build architecture-independent files here.
53 # Remove the .py from the end of each of these
54 mv debian/apt-p2p/usr/sbin/apt-p2p.py debian/apt-p2p/usr/sbin/apt-p2p
69 binary: binary-indep binary-arch
70 .PHONY: build clean binary-indep binary-arch binary install