This tutorial will guide you on how to compile and install OpenSSL on 64bit Windows. In case you are looking for how to compile and build on 32 bit Windows, you may visit to the following page Compiling and Installing OpenSSL for 32 bit Windows to get more information.

The following steps will guide you further on how to accomplish this tutorial.

  1. Make sure that your system environment is able to build x64 project. If you are unsure that, please visit to the following page Enable a 64-Bit Visual C++ Toolset on the Command Line to find out more about setting your x64 build environment.
  2. Create a new folder C:\openssl-1.0.1g
  3. Download latest OpenSSL source from I am using “openssl-1.0.1g.tar.gz” in this tutorial.
  4. Extract the file to C:\openssl-1.0.1g
  5. You will need to install Perl. Download & install ActiveState Perl @ ActiveState Perl
  6. Make sure you set “C:\perl\bin\” in the system path.
  7. Create a new folder “C:\openssl-1.0.1g-bin” which will hold all the built libraries in later.
  8. Open the command prompt windows.
  9. Run “call “c:\Program Files\Microsoft SDKs\Windows\v7.1\Bin\SetEnv.Cmd” /Release /x64″ to get visual studio environment setup.
  10. Browse to C:\openssl-1.0.1g
  11. Run “perl Configure VC-WIN64A no-asm – -prefix=C:\openssl-1.0.1g-bin”. This will configure to build using visual C++ in Win64 platform. Also, it will configure to install to “C:\openssl-1.0.1g-bin” in later step.
  12. Run “ms\do_win64a”.
  13. Run “nmake -f ms\ntdll.mak”. Compilation should start now and it will take some time to compile.
  14. Once the compilation is completed. You may test the output by running this command “nmake -f ms\ntdll.mak test”. You should get all the tests pass.
  15. It’s time to install the library now. Run this command “nmake -f ms\ntdll.mak install”. It will copy all the libraries to C:\openssl-1.0.1g-bin.

At this point, the OpenSSL libraries for 32 bit Windows should be ready.