Mercurial > hg > nginx-site
view xml/en/docs/howto_build_on_win32.xml @ 435:338c5aa982f8
Donor added.
author | Maxim Konovalov <maxim@nginx.com> |
---|---|
date | Wed, 29 Feb 2012 10:56:18 +0000 |
parents | a413dffb0557 |
children | 6135f3c95bf6 |
line wrap: on
line source
<?xml version="1.0"?> <!DOCTYPE article SYSTEM "../../../dtd/article.dtd"> <article name="How to build nginx on the Win32 Platform with Visual C" link="/en/docs/howto_build_on_win32.html" lang="en"> <section name="Prerequisites"> <para> To build nginx on the <registered>Microsoft Win32</registered> platform you need: <list> <item> Microsoft Visual C compiler. <registered>Microsoft Visual Studio</registered> 8 and 10 are known to work. </item> <item> <link url="http://www.mingw.org/wiki/MSYS">MSYS</link>. </item> <item> Perl, if you want to build <registered>OpenSSL</registered> and nginx with SSL support. For example <link url="http://www.activestate.com/activeperl">ActivePerl</link> or <link url="http://strawberryperl.com">Strawberry Perl</link>. </item> <item> <registered>Subversion</registered> client. Choose any from the <link url="http://subversion.apache.org/packages.html#windows">list</link> </item> <item> <link url="http://www.pcre.org">PCRE</link>, <link url="http://zlib.net">zlib</link> and <link url="http://www.openssl.org">OpenSSL</link> libraries sources. </item> </list> </para> </section> <section id="build_steps" name="Build steps"> <para> Ensure that paths to Perl, Subversion and MSYS bin directories are added to PATH environment variable before you start build. To set Visual C environment run vcvarsall.bat script from Visual C directory. </para> <para> To build nginx: <list> <item> Start MSYS bash. </item> <item> Check out nginx sources from the svn.nginx.org repository. For example: <programlisting> svn co svn://svn.nginx.org/tags/release-1.1.6 </programlisting> </item> <item> Create a build and lib directories, and unpack zlib, PCRE and OpenSSL libraries sources into lib directory: <programlisting> mkdir objs mkdir objs/lib cd objs/lib unzip ../../pcre-8.12.zip tar -xzf ../../zlib-1.2.5.tar.gz tar -xzf ../../openssl-1.0.0e.tar.gz </programlisting> </item> <item> Run configure script: <programlisting> auto/configure --with-cc=cl --builddir=objs --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 \ --with-cc-opt=-DFD_SETSIZE=1024 --with-pcre=objs/lib/pcre-8.12 \ --with-zlib=objs/lib/zlib-1.2.5 --with-openssl=objs/lib/openssl-1.0.0e \ --with-select_module --with-http_ssl_module --with-ipv6 </programlisting> </item> <item> Run make: <programlisting> nmake -f objs/Makefile </programlisting> </item> </list> </para> </section> <section id="see_also" name="See also"> <para> <list> <item> <link doc="windows.xml"/> </item> </list> </para> </section> </article>