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 102 103 104 105 106
|
#!/usr/bin/make -f
export DH_COMPAT=2
build:
$(checkdir)
make prefix=/usr RELEASE=true
touch build
clean:
$(checkdir)
-rm -f build
-make clean
-rm -f `find . -name "*~"`
-rm -rf debian/tmp `find debian/* -type d ! -name CVS ` debian/files* core
-rm -f debian/*substvars
dh_clean -k
binary-indep: checkroot build
$(checkdir)
mkdir -p debian/tmp/etc/modutils
mkdir -p debian/tmp/etc/default
mkdir -p debian/tmp/usr/share/doc/dnet-common
mkdir -p debian/tmp/sbin
echo "alias net-pf-12 decnet" > debian/tmp/etc/modutils/decnet
echo "post-install decnet echo \`grep executor /etc/decnet.conf | cut -f2\` > /proc/sys/net/decnet/node_address" >> debian/tmp/etc/modutils/decnet
echo '# DNET_INTERFACES specifies the names of ethernet interfaces whose' >> debian/tmp/etc/default/decnet
echo '# MAC address is to be set to the DECnet node address' >> debian/tmp/etc/default/decnet
echo "DNET_INTERFACES=\"all\"" >> debian/tmp/etc/default/decnet
echo '# DNET_DAEMONS lists the daemons to start when dnet-progs is installed.' >> debian/tmp/etc/default/decnet
echo "DNET_DAEMONS=\"dnetd phoned\"" >> debian/tmp/etc/default/decnet
cp README debian/tmp/usr/share/doc/dnet-common
cp Documentation/*README debian/tmp/usr/share/doc/dnet-common
cp apps/decnet.conf debian/tmp/usr/share/doc/dnet-common/decnet.conf.sample
make install DESTDIR=`pwd`/debian/tmp MAKEDEB=true RELEASE=true
mv debian/tmp/usr/man debian/tmp/usr/share
rm debian/tmp/usr/sbin/startnet
install -m755 apps/setether.sh debian/tmp/sbin/setether
dh_testversion 2
dh_installdirs -pdnet-common
dh_installchangelogs -pdnet-common
dh_installdocs -pdnet-common
dh_link -pdnet-common
dh_installdebconf -pdnet-common
dh_installinit -pdnet-common --init-script=decnet --update-rcd-params="start\ 39\ S\ .\ \ stop\ 11\ 1\ ."
dh_strip -pdnet-common
dh_movefiles -pdnet-common
dh_compress -pdnet-common
dh_fixperms -pdnet-common
dh_shlibdeps -pdnet-common
dh_gencontrol -pdnet-common
dh_makeshlibs -pdnet-common
dh_installdeb -pdnet-common
dh_md5sums -pdnet-common
dh_builddeb -pdnet-common
binary-arch: checkroot build
$(checkdir)
-rm -rf debian/tmp `find debian/* -type d ! -name CVS `
install -d debian/tmp
mkdir -p debian/tmp/etc/modutils
mkdir -p debian/tmp/etc/default
mkdir -p debian/tmp/usr/share/doc/libdnet
mkdir -p debian/tmp/usr/share/doc/libdnet-dev
mkdir -p debian/tmp/usr/share/doc/dnet-progs
mkdir -p debian/tmp/sbin
cp README debian/tmp/usr/share/doc/libdnet
cp README debian/tmp/usr/share/doc/dnet-progs
cp README debian/tmp/usr/share/doc/libdnet-dev
cp Documentation/*README debian/tmp/usr/share/doc/libdnet
cp Documentation/*README debian/tmp/usr/share/doc/dnet-progs
cp Documentation/*README debian/tmp/usr/share/doc/libdnet-dev
make install DESTDIR=`pwd`/debian/tmp MAKEDEB=true RELEASE=true
mv debian/tmp/usr/man debian/tmp/usr/share
mv debian/tmp/usr/sbin/startnet debian/tmp/sbin
dh_testversion 2
dh_installdirs -Ndnet-common
dh_installchangelogs -Ndnet-common
dh_installdocs -Ndnet-common
dh_link -Ndnet-common
dh_installdebconf -Ndnet-common
dh_installinit -pdnet-progs --init-script=dnet-progs
dh_strip -Ndnet-common
dh_movefiles -Ndnet-common
dh_compress -Ndnet-common
dh_fixperms -Ndnet-common
dh_shlibdeps -Ndnet-common
dh_gencontrol -Ndnet-common
dh_makeshlibs -Ndnet-common
dh_installdeb -Ndnet-common
dh_md5sums -Ndnet-common
dh_builddeb -Ndnet-common
define checkdir
test -f debian/rules
endef
binary: binary-indep binary-arch
checkroot:
$(checkdir)
test root = "`whoami`"
.PHONY: binary binary-arch binary-indep clean checkroot
|