1 da9456db 2003-07-09 alex #!/usr/bin/make -f
2 da9456db 2003-07-09 alex # debian/rules for ngIRCd
4 da9456db 2003-07-09 alex # $Id: rules,v 1.1 2003/07/09 20:23:35 alex Exp $
6 da9456db 2003-07-09 alex # Based on the sample debian/rules that uses debhelper,
7 da9456db 2003-07-09 alex # GNU copyright 1997 to 1999 by Joey Hess.
10 da9456db 2003-07-09 alex # Uncomment this to turn on verbose mode.
11 da9456db 2003-07-09 alex #export DH_VERBOSE=1
13 da9456db 2003-07-09 alex # These are used for cross-compiling and for saving the configure script
14 da9456db 2003-07-09 alex # from having to guess our platform (since we know it already)
15 da9456db 2003-07-09 alex DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
16 da9456db 2003-07-09 alex DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
18 da9456db 2003-07-09 alex CFLAGS = -Wall -g
20 da9456db 2003-07-09 alex ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
21 da9456db 2003-07-09 alex CFLAGS += -O0
23 da9456db 2003-07-09 alex CFLAGS += -O2
25 da9456db 2003-07-09 alex ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
26 da9456db 2003-07-09 alex INSTALL_PROGRAM += -s
29 da9456db 2003-07-09 alex config.status: configure
31 da9456db 2003-07-09 alex # Add here commands to configure the package.
32 da9456db 2003-07-09 alex ./configure --host=$(DEB_HOST_GNU_TYPE) --build=$(DEB_BUILD_GNU_TYPE) \
33 da9456db 2003-07-09 alex --prefix=/usr --sysconfdir=/etc/ngircd --mandir=\$${prefix}/share/man \
34 da9456db 2003-07-09 alex --with-syslog --with-zlib
36 da9456db 2003-07-09 alex build: build-stamp
38 da9456db 2003-07-09 alex build-stamp: config.status
41 da9456db 2003-07-09 alex # Add here commands to compile the package.
44 da9456db 2003-07-09 alex touch build-stamp
49 da9456db 2003-07-09 alex rm -f build-stamp
51 da9456db 2003-07-09 alex # Add here commands to clean up after the build process.
52 da9456db 2003-07-09 alex -$(MAKE) distclean
53 da9456db 2003-07-09 alex ifneq "$(wildcard /usr/share/misc/config.sub)" ""
54 da9456db 2003-07-09 alex cp -f /usr/share/misc/config.sub config.sub
56 da9456db 2003-07-09 alex ifneq "$(wildcard /usr/share/misc/config.guess)" ""
57 da9456db 2003-07-09 alex cp -f /usr/share/misc/config.guess config.guess
61 da9456db 2003-07-09 alex install: build
65 da9456db 2003-07-09 alex dh_installdirs
67 da9456db 2003-07-09 alex # Add here commands to install the package into debian/ngircd.
68 da9456db 2003-07-09 alex $(MAKE) install DESTDIR=$(CURDIR)/debian/ngircd
71 da9456db 2003-07-09 alex # Build architecture-independent files here.
72 da9456db 2003-07-09 alex binary-indep: build install
73 da9456db 2003-07-09 alex # We have nothing to do by default.
75 da9456db 2003-07-09 alex # Build architecture-dependent files here.
76 da9456db 2003-07-09 alex binary-arch: build install
79 da9456db 2003-07-09 alex dh_installchangelogs ChangeLog
80 da9456db 2003-07-09 alex dh_installdocs
81 da9456db 2003-07-09 alex dh_installinit
84 da9456db 2003-07-09 alex dh_fixperms -Xetc/ngircd.conf
85 da9456db 2003-07-09 alex dh_installdeb
86 da9456db 2003-07-09 alex dh_shlibdeps
87 da9456db 2003-07-09 alex dh_gencontrol
91 da9456db 2003-07-09 alex binary: binary-indep binary-arch
92 da9456db 2003-07-09 alex .PHONY: build clean binary-indep binary-arch binary install