3 # Made with the aid of debmake, by Christoph Lameter,
4 # based on the sample debian/rules file for GNU hello by Ian Jackson.
6 PYTHON:=/usr/bin/python
8 pyversion:=`$(PYTHON) -c 'import sys; print sys.version[:3]'`
10 pysite:=usr/lib/python$(pyversion)/site-packages
19 -find . -name '*.py[co]' | xargs rm -f
20 -rm -rf $(i) debian/files* core debian/substvars
25 $(pysite)/userdir_ldap \
26 var/www/userdir-ldap \
27 var/cache/userdir-ldap/web-cookies \
28 var/cache/userdir-ldap/hosts \
29 usr/share/doc/$(package)/samples \
30 etc/userdir-ldap/templates \
37 dh_installdirs $(instdirs)
39 echo "userdir_ldap" > $(i)/$(pysite)/userdir_ldap.pth
40 echo "userdir_gpg" >> $(i)/$(pysite)/userdir_ldap.pth
41 install -m 644 userdir_ldap.py userdir_gpg.py \
42 $(i)/$(pysite)/userdir_ldap/
43 install -m 755 {ud-forwardlist,ud-gpgimport,ud-info,ud-ldapshow,ud-userimport,ud-mailgate,ud-generate,ud-passchk,ud-useradd,ud-replicate,ud-xearth,ud-fingerserv,ud-echelon,ud-groupadd,ud-host,ud-zoneupdate} $(i)/usr/bin/
44 install -m 644 debian/ud-replicate.cron.d $(i)/etc/cron.d/ud-replicate
45 install -m 644 web/*.tab $(i)/var/www/userdir-ldap/
46 install -m 644 web/*.html $(i)/var/www/userdir-ldap/
47 install -m 644 web/*.cfg $(i)/var/www/userdir-ldap/
48 install -m 644 web/*.pm $(i)/var/www/userdir-ldap/
49 install -m 755 web/*.cgi $(i)/var/www/userdir-ldap/
50 chown www-data.www-data $(i)/var/cache/userdir-ldap/web-cookies/
51 chmod u=rwx,g=,o= $(i)/var/cache/userdir-ldap/web-cookies/
53 install -m 644 doc/{apache-config.txt,slapd-config.txt} $(i)/usr/share/doc/$(package)
54 install -m 644 doc/samples/ud-* $(i)/usr/share/doc/$(package)/samples
55 gzip -9 $(i)/usr/share/doc/$(package)/*.txt
56 install -m 644 userdir-ldap.conf $(i)/etc/userdir-ldap/
57 echo "# See /usr/share/doc/userdir-ldap" > $(i)/etc/userdir-ldap/generate.conf
58 chmod 644 $(i)/etc/userdir-ldap/generate.conf
59 install -m 644 templates/*-* $(i)/etc/userdir-ldap/templates/
62 dh_fixperms --exclude=web-cookies
65 $(PYTHON) debian/python-dep >> debian/substvars
73 # There are no architecture-dependent files to be uploaded
74 # generated by this package. If there were any they would be
78 # Below here is fairly generic really
80 binary: binary-indep binary-arch
82 .PHONY: binary binary-arch binary-indep clean