~udienz/nginx/nginx.head

« back to all changes in this revision

Viewing changes to debian/rules

  • Committer: Mahyuddin Susanto
  • Date: 2010-12-03 19:16:59 UTC
  • Revision ID: udienz@gmail.com-20101203191659-lcce9wyzm25dlhfc
Tags: 0.8.53-2
initial commit

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#!/usr/bin/make -f
 
2
 
 
3
CFLAGS = -Wall -g
 
4
 
 
5
DEB_BUILD_ARCH ?=$(shell dpkg-architecture -qDEB_BUILD_ARCH)
 
6
ifneq (,$(findstring sparc,$(DEB_BUILD_ARCH)))
 
7
   CONFIGURE_OPTS = --with-cc-opt="-m32 -mcpu=ultrasparc"
 
8
endif
 
9
 
 
10
ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
 
11
        CFLAGS += -O0
 
12
else
 
13
        CFLAGS += -O2
 
14
endif
 
15
 
 
16
config.sub:
 
17
        dh_testdir
 
18
ifneq "$(wildcard /usr/share/misc/config.sub)" ""
 
19
                cp -f /usr/share/misc/config.sub config.sub
 
20
endif
 
21
 
 
22
config.guess:
 
23
        dh_testdir
 
24
ifneq "$(wildcard /usr/share/misc/config.guess)" ""
 
25
                cp -f /usr/share/misc/config.guess config.guess
 
26
endif
 
27
 
 
28
config.status: config.sub config.guess
 
29
        ./configure \
 
30
            --conf-path=/etc/nginx/nginx.conf \
 
31
            --error-log-path=/var/log/nginx/error.log \
 
32
            --http-client-body-temp-path=/var/lib/nginx/body \
 
33
            --http-fastcgi-temp-path=/var/lib/nginx/fastcgi \
 
34
            --http-log-path=/var/log/nginx/access.log \
 
35
            --http-proxy-temp-path=/var/lib/nginx/proxy \
 
36
            --http-scgi-temp-path=/var/lib/nginx/scgi \
 
37
            --http-uwsgi-temp-path=/var/lib/nginx/uwsgi \
 
38
            --lock-path=/var/lock/nginx.lock \
 
39
            --pid-path=/var/run/nginx.pid \
 
40
            --with-debug \
 
41
            --with-http_dav_module \
 
42
            --with-http_flv_module \
 
43
            --with-http_geoip_module \
 
44
            --with-http_gzip_static_module \
 
45
            --with-http_image_filter_module \
 
46
            --with-http_perl_module \
 
47
            --with-http_realip_module \
 
48
            --with-http_stub_status_module \
 
49
            --with-http_ssl_module \
 
50
            --with-http_sub_module \
 
51
            --with-http_xslt_module \
 
52
            --with-ipv6 \
 
53
            --with-sha1=/usr/include/openssl \
 
54
            --with-md5=/usr/include/openssl \
 
55
            --with-mail \
 
56
            --with-mail_ssl_module \
 
57
            --add-module=$(CURDIR)/modules/nginx-upstream-fair \
 
58
            --add-module=$(CURDIR)/modules/nginx-echo \
 
59
            $(CONFIGURE_OPTS) >$@
 
60
        touch $@
 
61
 
 
62
build: config.status
 
63
        $(MAKE) build
 
64
 
 
65
build-stamp:
 
66
        dh_testdir
 
67
        touch $@
 
68
 
 
69
clean:
 
70
        dh_testdir
 
71
        dh_testroot
 
72
        rm -f config.sub config.guess
 
73
        rm -f build-stamp
 
74
        [ ! -f Makefile ] || $(MAKE) clean
 
75
        dh_clean
 
76
 
 
77
install:
 
78
        dh_testdir
 
79
        dh_testroot
 
80
        dh_prep
 
81
        dh_installdirs
 
82
        dh_install
 
83
 
 
84
binary-indep:
 
85
 
 
86
binary-arch: install
 
87
        dh_testdir
 
88
        dh_testroot
 
89
        dh_installman debian/nginx.1
 
90
        dh_installchangelogs CHANGES
 
91
        dh_installdocs
 
92
        dh_installexamples
 
93
        dh_installinit -r --no-start
 
94
        dh_installlogrotate
 
95
        dh_link
 
96
        dh_strip --dbg-package=nginx-dbg
 
97
        dh_compress
 
98
        dh_fixperms
 
99
        dh_installdeb
 
100
        dh_shlibdeps
 
101
        dh_gencontrol
 
102
        dh_md5sums
 
103
        dh_builddeb
 
104
 
 
105
binary: binary-indep binary-arch
 
106
 
 
107
.PHONY: build clean binary-indep binary-arch binary install