Windows platform compiled openssl-0.9.8k library (32-bit, 64-bit)

Source: Internet
Author: User

Recent work in the use of OpenSSL Win64 information, so the preliminary investigation, the summary results are as follows:

    Note that the OpenSSL code is in a directory that does not have Chinese, otherwise "nmake-f Ms\ntdll.mak" may prompt "illegal characters in macros" such as Error
One, Openssl WIN7 x64 compilation
   Environment: WIN7 64-bit, compiler: VS2010
   need to download Perl (such as http://downloads.activestate.com/ActivePerl/ Releases/5.16.3.1603/activeperl-5.16.3.1603-mswin32-x64-296746.msi) and Microsoft Platform SDK (VS2005 or VS2010)
0. Go to cmd, execute C:\Program Files (x86) \microsoft Visual Studio 10.0\vc\bin\amd64\vcvars64.bat
   #拷贝 C:\Program Files (x86) \microsoft Visual Studio 10.0\vc\bin\amd64\ml64.exe to Ms directory (no copy if Ml64.exe already available)
1. Start the VS2010 console, Ability to configure related environment variables-(can be omitted)
2. Compile command to enter the OPENSLL directory, such as CD C:\openssl-0.9.8k
3.x64:
  > Perl Configure vc-win64a
  > ms\do_win64a  Create makefile File
  > nmake-f ms\ntdll.mak   compiling the dynamic library (long wait Time)
  > Nmake-f ms\ntdll.mak test    Check for previous compilation success
  > nmake-f ms\ntdll.mak install   Installing compiled OP Enssl to the specified directory

Optional Directives
> nmake-f Ms\ntdll.mak Clean clears the compilation of the last OpenSSL dynamic library (choose whether to compile the static library as needed)
> nmake-f Ms\nt.mak Compile the static library (choose whether to compile the static library as needed)
> Nmake-f Ms\nt.mak Clean Clears compilation of the last OpenSSL static library (choose whether to compile the static library as needed)

Ii. compiling OpenSSL under Windows (32-bit)
Environment: WIN7 64-bit, compiler: VS2010
Need to download Perl (such as http://downloads.activestate.com/ActivePerl/releases/5.16.3.1603/ Activeperl-5.16.3.1603-mswin32-x64-296746.msi) and Microsoft Platform SDK (VS2005 or VS2010)
0. Go to cmd, execute C:\Program Files (x86) \microsoft Visual Studio 10.0\vc\bin\vcvars32.bat
#拷贝 C:\Program Files (x86) \microsoft Visual Studio 10.0\vc\bin\ml.exe to Ms directory (if Ml.exe is already available, you do not need to copy)
1. Start the VS2010 console and be able to configure the relevant environment variables-(can be omitted)
2. Enter the OPENSLL directory, such as CD C:\openssl-0.9.8k
3.x86 the Compile command:
> Perl Configure vc-win32
Create a Makefile file
If you use MASM, run the ms\do_masm command
If you use NASM, run Ms\do_nasm
If nothing is useless, run Ms\do_ms

> nmake-f ms\ntdll.mak compile Dynamic library (long wait Time)
> nmake-f ms\ntdll.mak Test Check whether the previous compilation was successful
> nmake-f Ms\ntdll.mak Install installs the compiled OpenSSL to the specified directory

Optional Directives
> nmake-f Ms\ntdll.mak Clean clears the compilation of the last OpenSSL dynamic library (choose whether to compile the static library as needed)
> nmake-f Ms\nt.mak Compile the static library (choose whether to compile the static library as needed)
> Nmake-f Ms\nt.mak Clean Clears compilation of the last OpenSSL static library (choose whether to compile the static library as needed)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.