1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101
|
#!/usr/bin/make -f
# urlview debian.rules file - based on
# GNU Hello (1.3) Copyright 1994,1995 by Ian Jackson.
#
package=urlview
build:
$(checkdir)
./configure --prefix=/usr --with-slang
$(MAKE)
sgml2html urlview.sgml
touch build
clean:
$(checkdir)
-rm -f build
-rm -f urlview.html
-$(MAKE) -i distclean || $(MAKE) -f Makefile.in distclean
-rm -rf *~ debian/tmp debian/*~ debian/files*
binary-indep: checkroot build
$(checkdir)
# There are no architecture-independent files to be uploaded
# generated by this package. If there were any they would be
# made here.
binary-arch: checkroot build
$(checkdir)
-rm -rf debian/tmp
# Install URLview files
install -d debian/tmp
cd debian/tmp && install -d `cat ../dirs \
| sed "s/%package%/$(package)/g"`
install -m 755 --strip urlview debian/tmp/usr/bin/urlview
install -m 644 urlview.man debian/tmp/usr/share/man/man1/urlview.1
gzip -v --best debian/tmp/usr/share/man/man1/urlview.1
install -m 644 AUTHORS debian/tmp/usr/share/doc/$(package)/
install -m 644 README debian/tmp/usr/share/doc/$(package)/
# Bug#19232
# install -m 644 INSTALL debian/tmp/usr/share/doc/$(package)/
install -m 644 text debian/tmp/usr/share/doc/$(package)/examples
install -m 644 debian/system.urlview \
debian/tmp/etc/$(package)/system.urlview
install -m 644 sample.urlview \
debian/tmp/usr/share/doc/$(package)/examples
install -m 755 debian/url_handler.sh debian/tmp/etc/$(package)
install -m 644 debian/README.Debian \
debian/tmp/usr/share/doc/$(package)
find debian/tmp/usr/share/doc/$(package) -size +4k -exec \
gzip -v --best \{\} \;
install -m 644 debian/changelog \
debian/tmp/usr/share/doc/$(package)/changelog.Debian
gzip -v --best \
debian/tmp/usr/share/doc/$(package)/changelog.Debian
install -m 644 ChangeLog debian/tmp/usr/share/doc/$(package)/changelog
gzip -v --best \
debian/tmp/usr/share/doc/$(package)/changelog
install -m 644 urlview.html debian/tmp/usr/share/doc/$(package)/html
install -m 644 urlview.sgml debian/tmp/usr/share/doc/$(package)
gzip -v --best \
debian/tmp/usr/share/doc/$(package)/urlview.sgml
install -m644 debian/dhelp \
debian/tmp/usr/share/doc/urlview/html/.dhelp
install -m644 debian/doc-base_urlview \
debian/tmp/usr/share/doc-base/urlview
install -m 644 debian/copyright debian/tmp/usr/share/doc/$(package)
# Create control files
install -d debian/tmp debian/tmp/DEBIAN
cp debian/control debian/tmp/DEBIAN
cp debian/conffiles debian/tmp/DEBIAN
cp debian/{postinst,prerm} debian/tmp/DEBIAN/.
chmod +x debian/tmp/DEBIAN/{postinst,prerm}
dpkg-shlibdeps $(package)
chown -R root.root debian/tmp
chmod -R go=rX debian/tmp
chmod -R u+w debian/tmp
dpkg-gencontrol -p$(package)
cd debian/tmp && \
find . -type f ! -regex "./DEBIAN/.*" -print0 | \
xargs -0 md5sum | \
sed -e '/\.\//s///' > DEBIAN/md5sums && \
chmod 644 DEBIAN/md5sums
dpkg --build debian/tmp ..
define checkdir
test -f debian/rules
endef
# Below here is fairly generic really
binary: binary-indep binary-arch
source diff:
@echo >&2 'source and diff are obsolete - use dpkg-source -b'; false
checkroot:
$(checkdir)
test root = "`whoami`"
.PHONY: binary binary-arch binary-indep clean checkroot
|