Test commit
[cogito/jonas.git] / debian / rules
blob92db7581dc089907e4fe4a72ae842819d0ba52b4
1 #!/usr/bin/make -f
3 # -*- makefile -*-
5 # Sample debian/rules that uses debhelper.
6 # This file was originally written by Joey Hess and Craig Small.
7 # As a special exception, when this file is copied by dh-make into a
8 # dh-make output file, you may use that output file without restriction.
9 # This special exception was added by Craig Small in version 0.37 of dh-make.
11 # Uncomment this to turn on verbose mode.
12 #export DH_VERBOSE=1
14 # these are used to override the variables in the upstream makefile
15 export prefix = /usr
16 export libdir = $(prefix)/share/cogito
18 DESTDIR = $(CURDIR)/debian/cogito
21 # On PowerPC we compile against the hand-crafted assembly, on all
22 # other architectures we compile against GPL'ed sha1 code lifted
23 # from Mozilla
25 HOST_ARCH=$(shell dpkg-architecture -qDEB_HOST_ARCH)
26 ifeq (${HOST_ARCH},powerpc)
27 export PPC_SHA1=YesPlease
28 else
29 export MOZILLA_SHA1=YesPlease
30 endif
32 CFLAGS = -Wall -g
34 ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
35 CFLAGS += -O0
36 else
37 CFLAGS += -O2
38 endif
40 configure: configure-stamp
41 configure-stamp:
42 dh_testdir
43 touch configure-stamp
46 build: build-stamp
48 build-stamp: configure-stamp
49 dh_testdir
50 $(MAKE)
51 $(MAKE) -C Documentation all
52 touch build-stamp
54 clean:
55 dh_testdir
56 dh_testroot
57 rm -f build-stamp configure-stamp
58 $(MAKE) clean
59 $(MAKE) -C Documentation clean
60 dh_clean
62 install: build
63 dh_testdir
64 dh_testroot
65 dh_clean -k
66 dh_installdirs
67 $(MAKE) install DESTDIR=$(CURDIR)/debian/cogito prefix=/usr
68 # $(RM) $(DESTDIR)/usr/bin/cg
69 install -m 0644 Documentation/*.html $(DESTDIR)/usr/share/doc/cogito/html
70 install -m 0644 Documentation/cg-*.txt $(DESTDIR)/usr/share/doc/cogito/txt
71 install -m 0644 Documentation/cogito.txt $(DESTDIR)/usr/share/doc/cogito/txt
72 install -m 0644 Documentation/*.1 $(DESTDIR)/usr/share/man/man1
73 install -m 0644 Documentation/*.7 $(DESTDIR)/usr/share/man/man7
75 # Build architecture-independent files here.
76 binary-indep: build install
77 # We have nothing to do by default.
79 # Build architecture-dependent files here.
80 binary-arch: build install
81 dh_testdir
82 dh_testroot
83 dh_installchangelogs
84 dh_installdocs
85 dh_installexamples
86 # dh_install
87 # dh_installmenu
88 # dh_installdebconf
89 # dh_installlogrotate
90 # dh_installemacsen
91 # dh_installpam
92 # dh_installmime
93 # dh_installinit
94 # dh_installcron
95 # dh_installinfo
96 dh_installman
97 dh_link
98 dh_strip
99 dh_compress
100 dh_fixperms
101 # dh_perl
102 # dh_python
103 # dh_makeshlibs
104 dh_installdeb
105 dh_shlibdeps
106 dh_gencontrol
107 dh_md5sums
108 dh_builddeb
110 binary: binary-indep binary-arch
111 .PHONY: build clean binary-indep binary-arch binary install configure