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
|
#!/usr/bin/make -f
# Made with the aid of debmake, by Christoph Lameter,
# based on the sample debian/rules file for GNU hello by Ian Jackson.
package=at
build:
$(checkdir)
-make -f Makefile.in distclean
./configure --prefix=/usr
make
touch build
clean:
$(checkdir)
-rm -f build
-make distclean
-rm -f `find . -name "*~" -o -name "*.bak"`
-rm -rf debian/tmp `find debian/* -type d` debian/files* core
-rm -f debian/*substvars
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 `find debian/* -type d`
install -d -m 755 debian/tmp
make install IROOT=`pwd`/debian/tmp
install -d -m 755 debian/tmp/etc/init.d/
install -m 755 debian/init.d debian/tmp/etc/init.d/atd
install -d -m 755 debian/tmp/DEBIAN
cd debian && install -m 755 postinst preinst postrm prerm tmp/DEBIAN
cd debian && install -m 644 conffiles tmp/DEBIAN
find debian/tmp/usr/doc debian/tmp/usr/man -type f | xargs gzip -9
find debian/tmp/usr/man -type l | xargs rm
cd debian/tmp/usr/man/man1 && ln -s at.1.gz batch.1.gz && ln -s at.1.gz atq.1.gz && ln -s at.1.gz atrm.1.gz
cd debian/tmp/usr/man/man5 && ln -s at_allow.5.gz at_deny.5.gz && rm -f at_deny.5
# Rename copyright to correct Debian name
cd debian/tmp/usr/doc/at; gunzip Copyright.gz; mv Copyright copyright
dpkg-shlibdeps at atd
dpkg-gencontrol -pat
cd debian/tmp && md5sum `find * -type f ! -regex "DEBIAN/.*"` >DEBIAN/md5sums </dev/null
dpkg --build debian/tmp ..
define checkdir
test -f debian/rules
endef
# Below here is fairly generic really
binary: binary-indep binary-arch
checkroot:
$(checkdir)
test root = "`whoami`"
.PHONY: binary binary-arch binary-indep clean checkroot
|