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
|
#!/usr/bin/make -f
tmp=debian/tmp
build:
binary-arch:
binary-indep:
install -d $(tmp)/usr/bin/
install -d $(tmp)/etc/X11/Xsession.d/
install -d $(tmp)/etc/init.d/
install -d $(tmp)/usr/share/scripts/
install -d $(tmp)/usr/share/doc/scripts/
install -d $(tmp)/usr/lib/python2.3/site-packages/
install -d $(tmp)/usr/lib/cgi-bin
install -d $(tmp)/usr/src/scripts
install -d $(tmp)/DEBIAN
install -m 755 pyfoo $(tmp)/usr/bin/
install -m 755 py2foo $(tmp)/usr/bin/
install -m 755 perlfoo $(tmp)/usr/bin/
install -m 755 rubyfoo $(tmp)/usr/bin/
install -m 755 make-foo $(tmp)/usr/bin/
install -m 755 lefty-foo $(tmp)/usr/bin/
install -m 4751 perlfoo $(tmp)/usr/bin/suidperlfoo2
install -m 4555 suidperlfoo $(tmp)/usr/bin/
install -m 755 tkfoo $(tmp)/usr/bin/
install -m 755 wishfoo $(tmp)/usr/bin/
install -m 644 xsession-test $(tmp)/etc/X11/Xsession.d/
# Permissions here aren't part of what's being tested, but let us exercise
# some other errors.
install -m 755 perl-bizarre-1 $(tmp)/usr/bin/
install -m 750 perl-bizarre-2 $(tmp)/usr/bin/
install -m 754 perl-bizarre-3 $(tmp)/usr/bin/
# First one should produce a warning; second one shouldn't.
install -m 755 gccbug.dpatch $(tmp)/usr/share/scripts/
install -m 755 gccbug.dpatch $(tmp)/usr/src/scripts/
install -m 755 init-skeleton $(tmp)/etc/init.d/skeleton
install -m 755 init-no-lsb $(tmp)/etc/init.d/no-lsb
install -m 755 init-lsb-broken $(tmp)/etc/init.d/lsb-broken
install -m 755 phpfoo $(tmp)/usr/share/scripts/
sed 's/php$$/php5/' phpfoo > $(tmp)/usr/share/scripts/php5foo
chmod 755 $(tmp)/usr/share/scripts/php5foo
echo "#!/usr/bin/perl" >> $(tmp)/usr/share/scripts/foobar.in
chmod 644 $(tmp)/usr/share/scripts/foobar.in
touch $(tmp)/usr/share/scripts/mono.exe
chmod 755 $(tmp)/usr/share/scripts/mono.exe
echo "#!/bin/sh" > $(tmp)/usr/share/scripts/foo\$$bar
chmod 755 $(tmp)/usr/share/scripts/foo\$$bar
echo "#!/bin/sh" > $(tmp)/usr/lib/cgi-bin/cgi-script
chmod 755 $(tmp)/usr/lib/cgi-bin/cgi-script
echo "#!/bin/sh" > $(tmp)/usr/bin/test.sh
chmod 755 $(tmp)/usr/bin/test.sh
# Should produce complaints about a missing debhelper dependency, but not a
# missing Python dependency.
dh_python
touch $(tmp)/usr/lib/python2.3/site-packages/test.pyc
cp debian/changelog $(tmp)/usr/share/doc/scripts/changelog
gzip -9 $(tmp)/usr/share/doc/scripts/changelog
cp debian/scripts.conffiles $(tmp)/DEBIAN/conffiles
install -m 755 debian/postinst $(tmp)/DEBIAN/postinst
install -m 755 debian/postrm $(tmp)/DEBIAN/postrm
dpkg-gencontrol -isp
dpkg --build $(tmp) ..
binary: binary-arch binary-indep
clean:
rm -rf debian/files $(tmp)
.PHONY: build binary-arch binary-indep binary clean
|