This repository has been archived by the owner on May 6, 2022. It is now read-only.
forked from openssl/openssl
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding Win10 Universal Platform support
ms\do_vsprojects14.bat will create a universal binary project as well as a universal test app. Fixing up the vs project scripts to create a proper solution file
- Loading branch information
Gilles Khouzam
committed
Apr 22, 2015
1 parent
e370799
commit 3e8a22c
Showing
43 changed files
with
2,075 additions
and
555 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,123 @@ | ||
|
||
INSTALLATION ON WINDOWS 10 ONECORE PLATFORM | ||
---------------------------------- | ||
|
||
[Instructions for building for Windows CE can be found in INSTALL.WCE] | ||
[Instructions for building for Win64 can be found in INSTALL.W64] | ||
[Instructions for building for Win32 can be found in INSTALL.W32] | ||
[Instructions for building for Windows Phone 8.0/8.1 or Windows Store 8.1 can be found in INSTALL.WINAPP] | ||
|
||
|
||
Requirments. | ||
- You need Perl location for Win32 or Win64 in your PATH environmental variable. | ||
- Visual Studio 2015 | ||
- Tools for Windows 10 [https://dev.windows.com/en-US/windows-10-developer-preview-tools] | ||
|
||
QUICK MULTI-PLATFORM INSTALL | ||
----------------------------------------------------------------------- | ||
|
||
Execute the following script in the source root tree. | ||
> ms\do_vsprojects14.bat | ||
|
||
Open visual studio solution created | ||
> vsout\openssl.sln | ||
|
||
|
||
This file will generate a solution file that contains 4 projects. | ||
|
||
2 OpenSSL Projects | ||
|
||
OneCore 10.0 DLL (Win32|x64|arm) (Debug|Release) | ||
OneCore 10.0 STATIC (Win32|x86|arm) (Debug|Release) | ||
|
||
2 Test Apps which host the tests and run them | ||
|
||
Run the test application to validate the libraries. It executes the same tests as the commandline | ||
test suite. | ||
|
||
Libraries are built on the following location | ||
|
||
vsout\$(ProjectConfiguration)\$(Configuration)\$(Arch)\bin | ||
|
||
Modify ms\do_vsprojects.bat for custom builds | ||
|
||
You can build this solution file via the command line using devenv.exe, or MSBuild.exe, or via the UI | ||
|
||
Once all configuration are build run | ||
|
||
> ms\do_packwincore.bat | ||
|
||
To pack the build output into vsout\package | ||
|
||
SINGLE PLATFORM INSTALL | ||
----------------------------------------------------------------------- | ||
Firstly you should run Configure with platform VC-WINCORE | ||
|
||
> perl Configure no-asm no-hw no-dso VC-WINCORE | ||
|
||
Next you need to build the Makefiles: | ||
|
||
> ms\do_wincore | ||
|
||
Then from CMD.exe, the following environment variables must be set for nmake build. | ||
|
||
INCLUDE | ||
LIB | ||
LIBPATH | ||
|
||
In addition nmake.exe, link.exe and cl.exe must be available in the environmental variable %PATH% | ||
|
||
Run ms\setVSvars.bat to set this environmental variables, and fix the path if needed, following flavours are supported, If your version is not supported by this batch you will need to manually set previous variables | ||
|
||
ms\setVSvars onecore10.0arm | ||
ms\setVSvars onecore10.0Win32 | ||
ms\setVSvars onecore10.01x64 | ||
|
||
Start nmake compilation with. | ||
|
||
> nmake -f ms\nt.mak init | ||
> nmake -f ms\nt.mak | ||
|
||
Alternatively you can generate DLLs with the following command | ||
|
||
> nmake -f ms\ntdll.mak | ||
|
||
If all is well it should compile and you will have libs for openssl. on the directory out32 or out32dll if DLL build. | ||
|
||
|
||
Tweaks: | ||
|
||
|
||
Troubleshooting | ||
--------------- | ||
|
||
Since the Win32 build is only occasionally tested it may not always compile | ||
cleanly. If you get an error about functions not having numbers assigned | ||
when you run ms\do_ms then this means the Win32 ordinal files are not up to | ||
date. You can do: | ||
|
||
> perl util\mkdef.pl crypto ssl update | ||
|
||
then ms\do_XXX should not give a warning any more. However the numbers that | ||
get assigned by this technique may not match those that eventually get | ||
assigned in the Git tree: so anything linked against this version of the | ||
library may need to be recompiled. | ||
|
||
If you get errors about unresolved symbols there are several possible | ||
causes. | ||
|
||
If this happens when the DLL is being linked and you have disabled some | ||
ciphers then it is possible the DEF file generator hasn't removed all | ||
the disabled symbols: the easiest solution is to edit the DEF files manually | ||
to delete them. The DEF files are ms\libeay32.def ms\ssleay32.def. | ||
|
||
Another cause is if you missed or ignored the errors about missing numbers | ||
mentioned above. | ||
|
||
|
||
Linking your application | ||
------------------------ | ||
|
||
If you link with static OpenSSL libraries [those built with ms/nt.mak], | ||
then you're expected to additionally link your application with | ||
WS2_32.LIB. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
@echo off | ||
if exist vsout\package rd /s /q vsout\package | ||
mkdir vsout\package | ||
mkdir vsout\package\include | ||
mkdir vsout\package\lib | ||
mkdir vsout\package\bin | ||
xcopy inc32 vsout\package\include /h /k /r /e /i /y >nul | ||
|
||
call :pack OneCore 10.0 Dll Unicode Debug Win32 | ||
call :pack OneCore 10.0 Dll Unicode Debug arm | ||
call :pack OneCore 10.0 Dll Unicode Debug x64 | ||
call :pack OneCore 10.0 Dll Unicode Release Win32 | ||
call :pack OneCore 10.0 Dll Unicode Release arm | ||
call :pack OneCore 10.0 Dll Unicode Release x64 | ||
call :pack OneCore 10.0 Static Unicode Debug Win32 | ||
call :pack OneCore 10.0 Static Unicode Debug arm | ||
call :pack OneCore 10.0 Static Unicode Debug x64 | ||
call :pack OneCore 10.0 Static Unicode Release Win32 | ||
call :pack OneCore 10.0 Static Unicode Release arm | ||
call :pack OneCore 10.0 Static Unicode Release x64 | ||
|
||
:pack | ||
echo %1 %2 %3 %4 %5 %6 | ||
if not exist vsout\package\lib\%1\%2\%3\%4\%5\%6 mkdir vsout\package\lib\%1\%2\%3\%4\%5\%6 > nul | ||
copy vsout\NT-%1-%2-%3-%4\%5\%6\bin\libeay32.lib vsout\package\lib\%1\%2\%3\%4\%5\%6\libeay32.lib | ||
copy vsout\NT-%1-%2-%3-%4\%5\%6\bin\ssleay32.lib vsout\package\lib\%1\%2\%3\%4\%5\%6\ssleay32.lib | ||
if "%3"=="Static" goto :eof | ||
if not exist vsout\package\bin\%1\%2\%3\%4\%5\%6 mkdir vsout\package\bin\%1\%2\%3\%4\%5\%6 > nul | ||
copy vsout\NT-%1-%2-%3-%4\%5\%6\bin\libeay32.dll vsout\package\bin\%1\%2\%3\%4\%5\%6\libeay32.dll | ||
copy vsout\NT-%1-%2-%3-%4\%5\%6\bin\ssleay32.dll vsout\package\bin\%1\%2\%3\%4\%5\%6\ssleay32.dll | ||
goto :eof |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.