2006-08-30 05:39:17 -05:00
|
|
|
|
2009-04-20 01:08:47 -05:00
|
|
|
VER = $(shell grep 'define NGINX_VERSION' src/core/nginx.h \
|
2013-03-28 03:47:25 -05:00
|
|
|
| sed -e 's/^.*"\(.*\)".*/\1/')
|
2009-04-20 01:08:47 -05:00
|
|
|
NGINX = nginx-$(VER)
|
|
|
|
TEMP = tmp
|
|
|
|
|
2016-12-24 09:01:14 -06:00
|
|
|
CC = cl
|
2009-04-20 01:08:47 -05:00
|
|
|
OBJS = objs.msvc8
|
2019-06-24 20:47:43 -05:00
|
|
|
OPENSSL = openssl-1.1.1c
|
2017-01-24 07:41:29 -06:00
|
|
|
ZLIB = zlib-1.2.11
|
2019-04-16 08:32:44 -05:00
|
|
|
PCRE = pcre-8.43
|
2006-08-30 05:39:17 -05:00
|
|
|
|
|
|
|
|
2013-03-22 10:47:18 -05:00
|
|
|
release: export
|
2006-08-30 05:39:17 -05:00
|
|
|
|
|
|
|
mv $(TEMP)/$(NGINX)/auto/configure $(TEMP)/$(NGINX)
|
|
|
|
|
|
|
|
# delete incomplete sources
|
|
|
|
rm $(TEMP)/$(NGINX)/src/event/ngx_event_acceptex.c
|
|
|
|
rm $(TEMP)/$(NGINX)/src/event/ngx_event_connectex.c
|
|
|
|
rm $(TEMP)/$(NGINX)/src/event/modules/ngx_iocp_module.*
|
|
|
|
rm -r $(TEMP)/$(NGINX)/src/os/win32
|
|
|
|
|
|
|
|
mv $(TEMP)/$(NGINX)/docs/text/LICENSE $(TEMP)/$(NGINX)
|
|
|
|
mv $(TEMP)/$(NGINX)/docs/text/README $(TEMP)/$(NGINX)
|
|
|
|
mv $(TEMP)/$(NGINX)/docs/html $(TEMP)/$(NGINX)
|
2010-11-29 09:23:06 -06:00
|
|
|
mv $(TEMP)/$(NGINX)/docs/man $(TEMP)/$(NGINX)
|
2006-08-30 05:39:17 -05:00
|
|
|
|
|
|
|
$(MAKE) -f docs/GNUmakefile changes
|
2006-09-18 07:26:31 -05:00
|
|
|
|
|
|
|
rm -r $(TEMP)/$(NGINX)/docs
|
|
|
|
rm -r $(TEMP)/$(NGINX)/misc
|
|
|
|
|
2006-09-18 07:42:53 -05:00
|
|
|
tar -c -z -f $(NGINX).tar.gz --directory $(TEMP) $(NGINX)
|
|
|
|
|
2006-09-18 07:26:31 -05:00
|
|
|
|
2013-03-22 10:47:18 -05:00
|
|
|
export:
|
|
|
|
rm -rf $(TEMP)
|
2013-04-25 08:41:45 -05:00
|
|
|
hg archive -X '.hg*' $(TEMP)/$(NGINX)
|
2013-03-22 10:47:18 -05:00
|
|
|
|
|
|
|
|
2011-10-17 10:09:34 -05:00
|
|
|
RELEASE:
|
2013-03-22 10:47:18 -05:00
|
|
|
hg ci -m nginx-$(VER)-RELEASE
|
|
|
|
hg tag -m "release-$(VER) tag" release-$(VER)
|
|
|
|
|
2013-04-25 08:41:45 -05:00
|
|
|
$(MAKE) -f misc/GNUmakefile release
|
2011-10-17 10:09:34 -05:00
|
|
|
|
|
|
|
|
2012-09-11 08:17:31 -05:00
|
|
|
win32:
|
|
|
|
./auto/configure \
|
2016-12-24 09:01:14 -06:00
|
|
|
--with-cc=$(CC) \
|
2012-10-30 06:09:38 -05:00
|
|
|
--builddir=$(OBJS) \
|
2012-09-11 08:17:31 -05:00
|
|
|
--with-debug \
|
|
|
|
--prefix= \
|
|
|
|
--conf-path=conf/nginx.conf \
|
|
|
|
--pid-path=logs/nginx.pid \
|
|
|
|
--http-log-path=logs/access.log \
|
|
|
|
--error-log-path=logs/error.log \
|
|
|
|
--sbin-path=nginx.exe \
|
|
|
|
--http-client-body-temp-path=temp/client_body_temp \
|
|
|
|
--http-proxy-temp-path=temp/proxy_temp \
|
|
|
|
--http-fastcgi-temp-path=temp/fastcgi_temp \
|
|
|
|
--http-scgi-temp-path=temp/scgi_temp \
|
|
|
|
--http-uwsgi-temp-path=temp/uwsgi_temp \
|
|
|
|
--with-cc-opt=-DFD_SETSIZE=1024 \
|
2012-10-30 06:09:38 -05:00
|
|
|
--with-pcre=$(OBJS)/lib/$(PCRE) \
|
|
|
|
--with-zlib=$(OBJS)/lib/$(ZLIB) \
|
2017-03-21 09:28:15 -05:00
|
|
|
--with-http_v2_module \
|
2012-09-11 08:17:31 -05:00
|
|
|
--with-http_realip_module \
|
|
|
|
--with-http_addition_module \
|
|
|
|
--with-http_sub_module \
|
|
|
|
--with-http_dav_module \
|
|
|
|
--with-http_stub_status_module \
|
|
|
|
--with-http_flv_module \
|
|
|
|
--with-http_mp4_module \
|
|
|
|
--with-http_gunzip_module \
|
|
|
|
--with-http_gzip_static_module \
|
2013-08-21 11:46:10 -05:00
|
|
|
--with-http_auth_request_module \
|
2012-09-11 08:17:31 -05:00
|
|
|
--with-http_random_index_module \
|
|
|
|
--with-http_secure_link_module \
|
2015-12-07 11:08:13 -06:00
|
|
|
--with-http_slice_module \
|
2012-09-11 08:17:31 -05:00
|
|
|
--with-mail \
|
2015-04-27 10:51:18 -05:00
|
|
|
--with-stream \
|
2012-10-30 06:09:38 -05:00
|
|
|
--with-openssl=$(OBJS)/lib/$(OPENSSL) \
|
2019-04-04 14:56:41 -05:00
|
|
|
--with-openssl-opt="no-asm no-tests -D_WIN32_WINNT=0x0501" \
|
2012-09-11 08:17:31 -05:00
|
|
|
--with-http_ssl_module \
|
|
|
|
--with-mail_ssl_module \
|
2016-10-04 08:38:14 -05:00
|
|
|
--with-stream_ssl_module
|
2006-08-30 05:39:17 -05:00
|
|
|
|
2009-04-20 01:08:47 -05:00
|
|
|
|
2013-03-22 10:47:18 -05:00
|
|
|
zip: export
|
|
|
|
rm -f $(NGINX).zip
|
2013-03-22 10:14:07 -05:00
|
|
|
|
|
|
|
mkdir -p $(TEMP)/$(NGINX)/docs.new
|
2009-04-20 01:08:47 -05:00
|
|
|
mkdir -p $(TEMP)/$(NGINX)/logs
|
|
|
|
mkdir -p $(TEMP)/$(NGINX)/temp
|
|
|
|
|
2012-08-02 09:58:36 -05:00
|
|
|
sed -i '' -e "s/$$/`printf '\r'`/" $(TEMP)/$(NGINX)/conf/*
|
2009-04-20 01:08:47 -05:00
|
|
|
|
2013-03-22 10:14:07 -05:00
|
|
|
mv $(TEMP)/$(NGINX)/docs/text/LICENSE $(TEMP)/$(NGINX)/docs.new
|
|
|
|
mv $(TEMP)/$(NGINX)/docs/text/README $(TEMP)/$(NGINX)/docs.new
|
|
|
|
mv $(TEMP)/$(NGINX)/docs/html $(TEMP)/$(NGINX)
|
2009-04-20 01:08:47 -05:00
|
|
|
|
2013-03-22 10:14:07 -05:00
|
|
|
rm -r $(TEMP)/$(NGINX)/docs
|
|
|
|
mv $(TEMP)/$(NGINX)/docs.new $(TEMP)/$(NGINX)/docs
|
2009-04-20 01:08:47 -05:00
|
|
|
|
|
|
|
cp -p $(OBJS)/nginx.exe $(TEMP)/$(NGINX)
|
|
|
|
|
2013-03-22 10:14:07 -05:00
|
|
|
$(MAKE) -f docs/GNUmakefile changes
|
2009-04-20 01:08:47 -05:00
|
|
|
mv $(TEMP)/$(NGINX)/CHANGES* $(TEMP)/$(NGINX)/docs/
|
|
|
|
|
|
|
|
cp -p $(OBJS)/lib/$(OPENSSL)/LICENSE \
|
|
|
|
$(TEMP)/$(NGINX)/docs/OpenSSL.LICENSE
|
|
|
|
|
2009-05-18 11:50:05 -05:00
|
|
|
cp -p $(OBJS)/lib/$(PCRE)/LICENCE \
|
|
|
|
$(TEMP)/$(NGINX)/docs/PCRE.LICENCE
|
2009-04-20 01:08:47 -05:00
|
|
|
|
2012-08-02 09:58:36 -05:00
|
|
|
sed -ne '/^ (C) 1995-20/,/^ jloup@gzip\.org/p' \
|
2009-04-20 01:08:47 -05:00
|
|
|
$(OBJS)/lib/$(ZLIB)/README \
|
|
|
|
> $(TEMP)/$(NGINX)/docs/zlib.LICENSE
|
|
|
|
|
|
|
|
touch -r $(OBJS)/lib/$(ZLIB)/README \
|
|
|
|
$(TEMP)/$(NGINX)/docs/zlib.LICENSE
|
|
|
|
|
2013-03-22 10:14:07 -05:00
|
|
|
rm -r $(TEMP)/$(NGINX)/auto
|
|
|
|
rm -r $(TEMP)/$(NGINX)/misc
|
|
|
|
rm -r $(TEMP)/$(NGINX)/src
|
|
|
|
|
2009-04-20 01:08:47 -05:00
|
|
|
cd $(TEMP) && zip -r ../$(NGINX).zip $(NGINX)
|
|
|
|
|
|
|
|
|
|
|
|
icons: src/os/win32/nginx.ico
|
2006-08-30 05:39:17 -05:00
|
|
|
|
2009-04-21 10:44:39 -05:00
|
|
|
# 48x48, 32x32 and 16x16 icons
|
2006-08-30 05:39:17 -05:00
|
|
|
|
2009-04-21 10:44:39 -05:00
|
|
|
src/os/win32/nginx.ico: src/os/win32/nginx_icon48.xpm \
|
|
|
|
src/os/win32/nginx_icon32.xpm \
|
2006-08-30 05:39:17 -05:00
|
|
|
src/os/win32/nginx_icon16.xpm
|
|
|
|
|
|
|
|
test -d $(TEMP) || mkdir $(TEMP)
|
|
|
|
|
2009-04-21 10:44:39 -05:00
|
|
|
xpmtoppm --alphaout=$(TEMP)/nginx48.pbm \
|
|
|
|
src/os/win32/nginx_icon48.xpm > $(TEMP)/nginx48.ppm
|
|
|
|
|
2006-08-30 05:39:17 -05:00
|
|
|
xpmtoppm --alphaout=$(TEMP)/nginx32.pbm \
|
|
|
|
src/os/win32/nginx_icon32.xpm > $(TEMP)/nginx32.ppm
|
|
|
|
|
|
|
|
xpmtoppm --alphaout=$(TEMP)/nginx16.pbm \
|
|
|
|
src/os/win32/nginx_icon16.xpm > $(TEMP)/nginx16.ppm
|
|
|
|
|
|
|
|
ppmtowinicon -output src/os/win32/nginx.ico -andpgms \
|
2009-04-21 10:44:39 -05:00
|
|
|
$(TEMP)/nginx48.ppm $(TEMP)/nginx48.pbm \
|
2006-08-30 05:39:17 -05:00
|
|
|
$(TEMP)/nginx32.ppm $(TEMP)/nginx32.pbm \
|
|
|
|
$(TEMP)/nginx16.ppm $(TEMP)/nginx16.pbm
|