*** empty log message ***
[findutils.git] / debian / rules
blob00e91f8b3074d2f04e74409be4f6e7cd355e8ce3
1 #!/usr/bin/make -f
2 # Sample debian.rules file - for GNU Hello (1.3).
3 # Copyright 1994,1995 by Ian Jackson.
4 # I hereby give you perpetual unlimited permission to copy,
5 # modify and relicense this file, provided that you do not remove
6 # my name from the file itself. (I assert my moral right of
7 # paternity under the Copyright, Designs and Patents Act 1988.)
8 # This file may have to be extensively modified
9 # Copyright 1996 by Kevin Dalley
13 CC = gcc
14 CFLAGS = -O2
15 LDFLAGS = -s
17 package = findutils
19 build:
20 $(checkdir)
21 ./configure --prefix=/usr
22 $(MAKE) localstatedir='$(prefix)/var/lib/locate' \
23 libexecdir=/usr/lib/locate \
24 CC="$(CC)" CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)"
25 cd doc ; makeinfo find.texi
26 touch build
28 clean:
29 $(checkdir)
30 -rm -f build
31 -$(MAKE) -i distclean || $(MAKE) -f Makefile.in distclean
32 -rm -rf *~ debian/tmp debian/*~ debian/files*
34 binary-indep: checkroot build
35 $(checkdir)
36 # There are no architecture-independent files to be uploaded
37 # generated by this package. If there were any they would be
38 # made here.
40 binary-arch: checkroot build
41 $(checkdir)
42 -rm -rf debian/tmp
43 install -d debian/tmp debian/tmp/DEBIAN
44 install -d debian/tmp/usr/doc/$(package)
45 install -d debian/tmp/usr/bin
46 install -d debian/tmp/usr/lib
47 install -d debian/tmp/usr/lib/locate
48 install -d debian/tmp/etc
49 install -d debian/tmp/etc/cron.daily
50 install -d debian/tmp/var
51 install -d debian/tmp/var/lib
52 install -d debian/tmp/var/lib/locate
53 install debian/{postinst,postrm,preinst,conffiles} debian/tmp/DEBIAN/.
54 install debian/cron.find debian/tmp/etc/cron.daily/find
55 install -m 0644 debian/updatedb.conf debian/tmp/etc/updatedb.conf
56 $(MAKE) prefix=`pwd`/debian/tmp/usr \
57 localstatedir=`pwd`/debian/tmp/var/lib/locate \
58 libexecdir=`pwd`/debian/tmp/usr/lib/locate \
59 CC="$(CC)" CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)" \
60 INSTALL_PROGRAM='install -c' \
61 install
62 gzip -9v debian/tmp/usr/info/*
63 install -m 0444 debian/copyright debian/tmp/usr/doc/$(package)/.
64 install -m 0444 debian/changelog \
65 debian/tmp/usr/doc/$(package)/changelog.Debian
66 install -m 0444 ChangeLog debian/tmp/usr/doc/$(package)/changelog
67 install -m 0444 debian/README.debian \
68 debian/tmp/usr/doc/$(package)
69 gzip -9v debian/tmp/usr/doc/$(package)/changelog{,.Debian}
70 dpkg-shlibdeps debian/tmp/usr/bin/{find,locate,xargs}
71 dpkg-gencontrol
72 dpkg --build debian/tmp ..
74 define checkdir
75 test -f find/find.c -a -f debian/rules
76 endef
78 # Below here is fairly generic really
80 binary: binary-indep binary-arch
82 source diff:
83 @echo >&2 'source and diff are obsolete - use dpkg-source -b'; false
85 checkroot:
86 $(checkdir)
87 test root = "`whoami`"
89 .PHONY: binary binary-arch binary-indep clean checkroot