3 # Sample debian/rules that uses debhelper.
4 # This file was originally written by Joey Hess and Craig Small.
5 # As a special exception, when this file is copied by dh-make into a
6 # dh-make output file, you may use that output file without restriction.
7 # This special exception was added by Craig Small in version 0.37 of dh-make.
9 # Uncomment this to turn on verbose mode.
12 DESTDIR=$(CURDIR)/debian/citadel-webcit
16 #to enable debugging: export DEB_BUILD_OPTIONS="debug profiling compression urldebug"
18 ifneq (,$(findstring profiling,$(DEB_BUILD_OPTIONS)))
19 PROFILE_ARGS= --with-gprof
21 ifneq (,$(findstring debug,$(DEB_BUILD_OPTIONS)))
22 CFLAGS += -O0 -ggdb -rdynamic -MD -MP -D TECH_PREVIEW
24 EXTRA_ARGS = --with-backtrace
28 ifneq (,$(findstring urldebug,$(DEB_BUILD_OPTIONS)))
29 CFLAGS += -D DEBUG_URLSTRINGS
32 configure: configure-stamp
35 CFLAGS="$(CFLAGS)" ./configure \
36 --host=$(DEB_HOST_GNU_TYPE) \
37 --build=$(DEB_BUILD_GNU_TYPE) \
39 --with-wwwdir=/usr/share/citadel-webcit \
40 --with-localedir=/usr/share/ \
41 --with-editordir=/usr/share/tinymce/www \
42 --with-rundir=/var/run/citadel \
43 --with-ical --with-db --with-ldap \
44 --with-ssldir=/etc/ssl/webcit/ \
45 --with-ssl --with-libiconf \
46 --with-newt --with-included-gettext \
47 --with-datadir=/var/run/citadel \
48 --enable-debug $(EXTRA_ARGS) $(PROFILE_ARGS)
55 build-stamp: configure-stamp
58 # Add here commands to compile the package.
60 #docbook-to-man debian/webcit.sgml > webcit.1
67 rm -f build-stamp configure-stamp
69 # Add here commands to clean up after the build process.
79 $(MAKE) install-bin install-locale install-wwwdata DESTDIR=$(DESTDIR)
80 rm $(DESTDIR)/usr/share/citadel-webcit/static/prototype.js
81 # mkdir -p $(DESTDIR)/etc/citadel; cp webcit.conf $(DESTDIR)/etc/citadel/
85 # Build architecture-independent files here.
86 binary-indep: build install
87 # We have nothing to do by default.
89 # Build architecture-dependent files here.
90 binary-arch: build install
103 dh_installinit --name=webcit
120 binary: binary-indep binary-arch
121 .PHONY: build clean binary-indep binary-arch binary install configure