With CFLAGS set as in 7da71a7b141a, OpenSSL compilation drops various
non-important compiler options. To avoid this, a define is added
instead - OpenSSL is smart enough to recognize -D... in Configure
arguments.
OpenSSL 1.1.0 and above uses BCrypt if available (Windows 7 or higher).
This results in an unusable binary on older Windows versions, when building
with newer Windows SDK (such as 7.0A). Using CFLAGS to define _WIN32_WINNT
allows to set a desired ABI and make sure the binary works with Windows XP.
To not mix with other potential CFLAGS uses, it is set in GNUmakefile.
When building OpenSSL 1.1.1b, as used for win32 builds, with tests
it takes about twice as long and near ~1GB of additional disk space.
Using "no-tests" OpenSSL configuration option allows to skip them.
Since such an option is supported since OpenSSL 1.1.1 only, it is
residing here and not in configure.
Previously, select was compiled in by default, but the NGX_HAVE_SELECT
macro was not set, resulting in iocp being used by default unless
the "--with-select_module" configure option was explicitly specified.
Since the iocp module is not finished and does not work properly, this
effectively meant that the "--with-select_module" option was mandatory.
With the change NGX_HAVE_SELECT is properly set, making "--with-select_module"
optional. Accordingly, it is removed from misc/GNUmakefile win32 target.
This allows to set a different one from command line when needed.
For example, to configure nginx with gcc as a compiler one could
use "make -f misc/GNUmakefile win32 CC=gcc".
IPv6 now compiled-in automatically if support is found. If there is a need
to disable it for some reason, --with-cc-opt="-DNGX_HAVE_INET6=0" can be used
for this.
Note that as of OpenSSL 1.0.0, the "ms\do_ms" script (previously documented
to be used if one doesn't want to use the assembly language files) tries to
use MASM. Additionally, OpenSSL 1.0.2 finally broke MASM support. To fix
this, we now explicitly use "no-asm" in OpenSSL options.