diff options
author | Maxim Dounin <mdounin@mdounin.ru> | 2023-02-23 18:16:08 +0300 |
---|---|---|
committer | Maxim Dounin <mdounin@mdounin.ru> | 2023-02-23 18:16:08 +0300 |
commit | dad6ec3aa63fbd3b427d74842fa659f7a0b82f3b (patch) | |
tree | 83dbe41a2c059d7b78f2e6579175072b2a099ee0 /auto/lib | |
parent | 62b790c3318a56971e461a1e1f5b79197b604e89 (diff) | |
download | nginx-dad6ec3aa63fbd3b427d74842fa659f7a0b82f3b.tar.gz nginx-dad6ec3aa63fbd3b427d74842fa659f7a0b82f3b.zip |
Win32: OpenSSL compilation for x64 targets with MSVC.
To ensure proper target selection the NGX_MACHINE variable is now set
based on the MSVC compiler output, and the OpenSSL target is set based
on it.
This is not important as long as "no-asm" is used (as in misc/GNUmakefile
and win32 build instructions), but might be beneficial if someone is trying
to build OpenSSL with assembler code.
Diffstat (limited to 'auto/lib')
-rw-r--r-- | auto/lib/openssl/make | 15 | ||||
-rw-r--r-- | auto/lib/openssl/makefile.msvc | 2 |
2 files changed, 15 insertions, 2 deletions
diff --git a/auto/lib/openssl/make b/auto/lib/openssl/make index 126a23875..a7e9369e7 100644 --- a/auto/lib/openssl/make +++ b/auto/lib/openssl/make @@ -7,11 +7,24 @@ case "$CC" in cl) + case "$NGX_MACHINE" in + + amd64) + OPENSSL_TARGET=VC-WIN64A + ;; + + *) + OPENSSL_TARGET=VC-WIN32 + ;; + + esac + cat << END >> $NGX_MAKEFILE $OPENSSL/openssl/include/openssl/ssl.h: $NGX_MAKEFILE \$(MAKE) -f auto/lib/openssl/makefile.msvc \ - OPENSSL="$OPENSSL" OPENSSL_OPT="$OPENSSL_OPT" + OPENSSL="$OPENSSL" OPENSSL_OPT="$OPENSSL_OPT" \ + OPENSSL_TARGET="$OPENSSL_TARGET" END diff --git a/auto/lib/openssl/makefile.msvc b/auto/lib/openssl/makefile.msvc index a30b28669..ed17cde08 100644 --- a/auto/lib/openssl/makefile.msvc +++ b/auto/lib/openssl/makefile.msvc @@ -6,7 +6,7 @@ all: cd $(OPENSSL) - perl Configure VC-WIN32 no-shared no-threads \ + perl Configure $(OPENSSL_TARGET) no-shared no-threads \ --prefix="%cd%/openssl" \ --openssldir="%cd%/openssl/ssl" \ $(OPENSSL_OPT) |