File: Makefile

package info (click to toggle)
uif 1.0.5-3
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 228 kB
  • ctags: 31
  • sloc: perl: 1,812; sh: 231; makefile: 67
file content (42 lines) | stat: -rw-r--r-- 1,685 bytes parent folder | download | duplicates (5)
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
# uif-1.0 Installer Makefile
# 
# Cajus Pollmeier <pollmeier@gonicus.de>
# Jrg Platte     <joerg.platte@gmx.de>

# Change here to install to different location
PREFIX = ${DESTDIR}
VERS = `sed -n "s/[^ ]* (\([0-9.]*\)-[0-9]*).*/\1/p" debian/changelog | head -1`

install:
	@echo "Installing uif script..."

	@# create directories
	install -o root -g root -m 700 -d ${PREFIX}/etc/uif
	install -o root -g root -m 755 -d ${PREFIX}/etc/default
	install -o root -g root -m 755 -d ${PREFIX}/etc/init.d
	install -o root -g root -m 755 -d ${PREFIX}/etc/ldap/schema
	install -o root -g root -m 755 -d ${PREFIX}/usr/sbin
	install -o root -g root -m 755 -d ${PREFIX}/usr/share/doc/uif
	install -o root -g root -m 755 -d ${PREFIX}/usr/share/man/man8
	install -o root -g root -m 755 -d ${PREFIX}/usr/share/man/man5
	
	@# install files
	install -o root -g root -m 700 uif.pl ${PREFIX}/usr/sbin/uif
	install -o root -g root -m 600 default ${PREFIX}/etc/default/uif
	install -o root -g root -m 600 services ${PREFIX}/etc/uif
	install -o root -g root -m 755 uif ${PREFIX}/etc/init.d
	install -o root -g root -m 644 uif.schema ${PREFIX}/etc/ldap/schema

	@# install documentation
	install -o root -g root -m 644 docs/uif.conf.tmpl ${PREFIX}/usr/share/doc/uif
	install -o root -g root -m 644 docs/examples.txt ${PREFIX}/usr/share/doc/uif
	install -o root -g root -m 644 uif.8 ${PREFIX}/usr/share/man/man8
	install -o root -g root -m 644 uif.conf.5 ${PREFIX}/usr/share/man/man5

deb:
	@echo "Generating debian package..."
	[ -d /tmp/uif-${VERS} ] && rm -rf /tmp/uif-${VERS} || /bin/true
	cp -a ../uif /tmp/uif-${VERS}
	cd /tmp/uif-${VERS} && fakeroot make -f debian/rules binary
	rm -rf /tmp/uif-${VERS}