1
|
#!/usr/bin/make -f
|
2
|
# GNU copyright 1997 to 1999 by Joey Hess.
|
3
|
|
4
|
# Uncomment this to turn on verbose mode.
|
5
|
#export DH_VERBOSE=1
|
6
|
|
7
|
PYTHON=/usr/bin/python
|
8
|
|
9
|
LARPE_USER = www-data
|
10
|
LARPE_GROUP = www-data
|
11
|
|
12
|
ifneq (,$(findstring debug,$(DEB_BUILD_OPTIONS)))
|
13
|
CFLAGS += -g
|
14
|
endif
|
15
|
ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
|
16
|
INSTALL_PROGRAM += -s
|
17
|
endif
|
18
|
|
19
|
build: build-stamp
|
20
|
|
21
|
build-stamp:
|
22
|
dh_testdir
|
23
|
touch build-stamp
|
24
|
|
25
|
clean:
|
26
|
dh_testdir
|
27
|
dh_testroot
|
28
|
rm -f build-stamp
|
29
|
|
30
|
make clean
|
31
|
|
32
|
dh_clean
|
33
|
|
34
|
install: build
|
35
|
dh_testdir
|
36
|
dh_testroot
|
37
|
dh_clean -k
|
38
|
dh_installdirs
|
39
|
|
40
|
make install prefix=/usr DESTDIR=$(CURDIR)/debian/larpe
|
41
|
# Apache Vhost
|
42
|
dh_install conf/apache2-vhost-larpe etc/apache2/sites-available
|
43
|
# Apache reload script
|
44
|
dh_install debian/larpe-reload-apache2-script usr/sbin
|
45
|
|
46
|
# Give files ownership to Larpe user and group
|
47
|
chown -R $(LARPE_USER):$(LARPE_GROUP) $(CURDIR)/debian/larpe/usr/share/larpe/
|
48
|
chown -R $(LARPE_USER):$(LARPE_GROUP) $(CURDIR)/debian/larpe/var/lib/larpe/
|
49
|
chgrp $(LARPE_GROUP) $(CURDIR)/debian/larpe/usr/sbin/larpe-reload-apache2
|
50
|
|
51
|
# Build architecture-independent files here.
|
52
|
binary-indep: build install
|
53
|
# We have nothing to do by default.
|
54
|
|
55
|
# Build architecture-dependent files here.
|
56
|
binary-arch: build install
|
57
|
dh_testdir
|
58
|
dh_testroot
|
59
|
dh_installdocs
|
60
|
dh_installinit
|
61
|
dh_installchangelogs
|
62
|
dh_link
|
63
|
dh_strip
|
64
|
dh_compress
|
65
|
dh_fixperms -X /var/lib/larpe -X /usr/sbin/larpe-reload-apache2
|
66
|
dh_pysupport
|
67
|
dh_installdeb
|
68
|
dh_shlibdeps
|
69
|
dh_gencontrol
|
70
|
dh_md5sums
|
71
|
dh_builddeb
|
72
|
|
73
|
binary: binary-indep binary-arch
|
74
|
.PHONY: build clean binary-indep binary-arch binary install
|