~ubuntu-branches/ubuntu/breezy/ratfor/breezy

« back to all changes in this revision

Viewing changes to debian/rules

  • Committer: Bazaar Package Importer
  • Author(s): Alan Bain
  • Date: 1999-10-26 14:00:00 UTC
  • Revision ID: james.westby@ubuntu.com-19991026140000-328m9rxvjr4gg6ne
Tags: 1.0-7
* Changelog now compressed
* FHS file locations adopted

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#!/usr/bin/make -f
 
2
## This is the debian.rules file for the package
 
3
## ratfor, by Emilio C. Lopes <ecl@finpe.if.usp.br>.
 
4
## updated by Alan Bain <afrb2@cam.ac.uk>.
 
5
 
 
6
## updated based on f2c's files and hello package
 
7
package=ratfor
 
8
 
 
9
## The architecture
 
10
arch = $(shell dpkg --print-architecture)
 
11
 
 
12
 
 
13
build:  
 
14
        $(checkdir)
 
15
## Builds the binary package.
 
16
        make -f Makefile
 
17
        touch stamp-build
 
18
 
 
19
clean: $(checkdir)
 
20
## Undoes the effect of `make -f debian.rules build'.
 
21
        make -f Makefile clean
 
22
        rm -f stamp-build debian/files debian/substvars
 
23
        rm -rf debian/tmp
 
24
 
 
25
binary-indep:  checkroot build
 
26
        $(checkdir)
 
27
 
 
28
binary-arch: checkroot build 
 
29
        $(checkdir)
 
30
## Makes a binary package.
 
31
        test -f stamp-build || make -f debian/rules build
 
32
        rm -rf debian/tmp >& /dev/null
 
33
        install -d -o root -g root -m 755 debian/tmp
 
34
        chmod g-s debian/tmp
 
35
        install -d -o root -g root -m 755 debian/tmp/usr/bin
 
36
        install -s -o root -g root -m 755 ratfor debian/tmp/usr/bin
 
37
        install -d -o root -g root -m 755 debian/tmp/usr/share/man/man1
 
38
        install -o root -g root -m 644 ratfor.1 debian/tmp/usr/share/man/man1
 
39
        gzip -9f debian/tmp/usr/share/man/man1/ratfor.1
 
40
        install -d -o root -g root -m 755 debian/tmp/usr/share/doc/$(package)
 
41
        install -o root -g root -m 644  BUGS\
 
42
          debian/tmp/usr/share/doc/$(package)
 
43
## do package copyright
 
44
        install -d -o root -g root -m 755 debian/tmp/usr/share/doc/$(package)
 
45
        install -o root -g root -m 644  debian/copyright \
 
46
        debian/tmp/usr/share/doc/$(package)/copyright
 
47
        install -d -o root -g root -m 755 debian/tmp/usr/share/doc/$(package)/examples
 
48
        install -o root -g root -m 644 *.r \
 
49
          debian/tmp/usr/share/doc/$(package)/examples
 
50
        gzip -9f debian/tmp/usr/share/doc/$(package)/examples/*.r
 
51
        install -d -o root -g root -m 755 debian/tmp/DEBIAN
 
52
        install -m 755 debian/postinst \
 
53
                                debian/tmp/DEBIAN/postinst
 
54
        install -m 755 debian/prerm \
 
55
                                debian/tmp/DEBIAN/prerm
 
56
 
 
57
        install -c -m 0644 debian/changelog \
 
58
                              debian/tmp/usr/share/doc/$(package)/changelog.Debian 
 
59
        gzip -9 debian/tmp/usr/share/doc/$(package)/changelog.Debian
 
60
        dpkg-shlibdeps ./ratfor                                                
 
61
        dpkg-gencontrol                                                         
 
62
        chown -R root.root debian/tmp                                           
 
63
        chmod -R go-ws debian/tmp
 
64
        dpkg --build debian/tmp ..
 
65
 
 
66
define checkdir                                                                 
 
67
        test -f rat4.c -a -f debian/rules                                 
 
68
endef                                                                           
 
69
                                                                               
 
70
## Below Here is Generic                                                        
 
71
                                                                                
 
72
binary: binary-indep binary-arch                                                
 
73
                                                                                
 
74
source diff:                                                                    
 
75
        @echo >&2 'source and diff are obsolete - use dpkg-source -b'; false    
 
76
                                                                                
 
77
dist:  binary source diff changes                                               
 
78
 
 
79
checkroot:
 
80
        $(checkdir)
 
81
        test root = "`whoami`"
 
82
.PHONY: binary binary-arch binary-indep clean checkroot
 
83