gPodder 3.7.0 for Harmattan
[gpodder.git] / debian / rules
blob6bb816540969a6693bfd0b719c1e373c44adc2c8
1 #!/usr/bin/make -f
2 # -*- makefile -*-
3 # Sample debian/rules that uses debhelper.
4 # This file was originally written by Joey Hess and Craig Small.
5 # As a special exception, when this file is copied by dh-make into a
6 # dh-make output file, you may use that output file without restriction.
7 # This special exception was added by Craig Small in version 0.37 of dh-make.
9 # Uncomment this to turn on verbose mode.
10 #export DH_VERBOSE=1
12 DOCS = README
14 PYTHON = python2.6
15 SETUP = GPODDER_INSTALL_UIS="cli qml" $(PYTHON) setup.py
17 PACKAGE = gpodder
18 DESTDIR = debian/$(PACKAGE)
19 PREFIX = usr
20 OPTDIR = opt/gpodder
22 ORG_DIST_PACKAGES = $(PREFIX)/lib/$(PYTHON)/dist-packages
23 OPT_DIST_PACKAGES = $(OPTDIR)/lib/$(PYTHON)/dist-packages
25 configure: configure-stamp
26 configure-stamp:
27 dh_testdir
28 touch configure-stamp
30 build: build-stamp
31 build-stamp: configure-stamp
32 dh_testdir
33 PYTHON=$(PYTHON) make share/dbus-1/services/org.gpodder.service
34 PYTHON=$(PYTHON) make share/applications/gpodder.desktop
35 PYTHON=$(PYTHON) make messages
36 ${SETUP} build
37 touch build-stamp
39 clean:
40 dh_testdir
41 dh_testroot
42 rm -f build-stamp configure-stamp
43 ${SETUP} clean --all
44 rm -rf build dist
45 dh_clean
46 PYTHON=$(PYTHON) make clean
48 install: build
49 dh_testdir
50 dh_testroot
51 dh_clean -k
52 dh_installdirs
53 ${SETUP} install --no-compile --install-layout=deb --root='$(DESTDIR)' --prefix='$(PREFIX)'
54 # Optification
55 mkdir -p $(DESTDIR)/$(OPTDIR)/share
56 mv $(DESTDIR)/$(PREFIX)/share/{gpodder,locale,man} $(DESTDIR)/$(OPTDIR)/share/
57 mkdir -p $(DESTDIR)/$(OPT_DIST_PACKAGES)
58 rm -f $(DESTDIR)/$(ORG_DIST_PACKAGES)/gpodder-?.?.?.egg-info
59 mv $(DESTDIR)/$(ORG_DIST_PACKAGES)/* $(DESTDIR)/$(OPT_DIST_PACKAGES)/
60 mkdir -p $(DESTDIR)/$(OPTDIR)/bin
61 mv $(DESTDIR)/$(PREFIX)/bin/* $(DESTDIR)/$(OPTDIR)/bin/
62 mv $(DESTDIR)/$(PREFIX)/share/pixmaps/gpodder.png $(DESTDIR)/$(OPTDIR)/gpodder.png
63 rm -rf $(DESTDIR)/$(PREFIX)/share/{icons,pixmaps}/
64 rm -rf $(DESTDIR)/$(PREFIX)/{bin,lib}/
66 binary-arch:
68 binary-indep: build install
69 dh_testdir
70 dh_testroot
71 dh_installdocs $(DOCS)
72 dh_installman
73 dh_compress
74 dh_fixperms
75 dh_installdeb
76 dh_gencontrol
77 dh_md5sums
78 dh_builddeb
80 binary: binary-indep
82 .PHONY: build clean binary-indep binary-arch binary install configure