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
|
#! /usr/bin/make -f
package=csh
# Additional documentation to be installed under /usr/doc/<PACKAGENAME>
DOCFILES=USD.doc/csh.ps USD.doc/csh.txt
binary: binary-arch binary-indep
binary-indep:
binary-arch: build
$(RM) -r debian/tmp
install -d -m 755 debian/tmp/DEBIAN
if [ -f debian/conffiles ]; then \
install -c -g root -m 644 -o root debian/conffiles \
debian/tmp/DEBIAN/conffiles; \
fi
if [ -f debian/initscript ]; then \
install -d -g root -m 0755 -o root debian/tmp/etc/init.d; \
install -c -g root -m 755 -o root debian/initscript \
debian/tmp/etc/init.d/$(package); \
fi
if [ -f debian/postinst ]; then \
install -c -g root -m 755 -o root debian/postinst \
debian/tmp/DEBIAN/postinst; \
fi
if [ -f debian/postrm ]; then \
install -c -g root -m 755 -o root debian/postrm \
debian/tmp/DEBIAN/postrm; \
fi
if [ -f debian/preinst ]; then \
install -c -g root -m 755 -o root debian/preinst \
debian/tmp/DEBIAN/preinst; \
fi
if [ -f debian/prerm ]; then \
install -c -g root -m 755 -o root debian/prerm \
debian/tmp/DEBIAN/prerm; \
fi
install -d debian/tmp/usr/doc/$(package)
install -m 644 debian/copyright debian/tmp/usr/doc/$(package)
install -m 644 debian/changelog debian/tmp/usr/doc/$(package)/changelog.Debian
gzip -f9 debian/tmp/usr/doc/$(package)/changelog*
if [ -n "$(DOCFILES)" ]; then \
for i in $(DOCFILES); \
do \
install -m 644 $$i debian/tmp/usr/doc/$(package)/`basename $$i`; \
gzip -9fv debian/tmp/usr/doc/$(package)/`basename $$i`; \
done; \
fi
make PREFIX=debian/tmp install
mv -f debian/tmp/usr/man/man1/csh.1 debian/tmp/usr/man/man1/bcsh.1
gzip -9f debian/tmp/usr/man/man1/bcsh.1
dpkg-shlibdeps csh
dpkg-gencontrol
chown -R root.root debian/tmp
chmod -R g-ws debian/tmp
dpkg --build debian/tmp ..
build:
make CFLAGS='-O2 -g -Wall' LDFLAGS=''
(cd USD.doc; make all)
touch build
clean:
$(MAKE) clean
(cd USD.doc; $(MAKE) clean)
$(RM) build const.h
$(RM) -r debian/tmp debian/*~ debian/files*
|