microsoft / openssl

A cross-platform cryptographic library
133 stars 57 forks source link

Fix ms/setVSvars.bat for new windows.foundation.foundationcontract & windows.foundation.universalapicontract #31

Open brodycj opened 8 years ago

brodycj commented 8 years ago

I had to make the following change to build the OpenSSL_1_0_2_WinRT-stable branch using a recent Visual Studio Community 2015 update:

diff --git a/ms/setVSvars.bat b/ms/setVSvars.bat
index 5da96bb..7bc3f8a 100644
--- a/ms/setVSvars.bat
+++ b/ms/setVSvars.bat
@@ -177,7 +177,7 @@ exit /b
    set PATH=%_VS14VC\Bin%;%PATH%
    set INCLUDE=%_VS14VC%\include;%_WKITS10%\Include\%_WKITS10VER%\um;%_WKITS10%\Include\%_WKITS10VER%\shared;%_WKITS10%\Include\%_WKITS10VER%\winrt;%_WKITS10%\Include\%_WKITS10VER%\ucrt;
    set LIB=%_VS14VC%\lib\store\%_VCLibPlat%;%_WKITS10%\lib\%_WKITS10VER%\um\%_VCPlatform%;%_WKITS10%\Lib\%_WKITS10VER%\ucrt\%_VCPlatform%;
-   set LIBPATH=%_WKITS10%\UnionMetadata\Facade;%_VS14VC%\vcpackages;;%_WKITS10%\references\windows.foundation.foundationcontract\1.0.0.0\;;%_WKITS10%\references\windows.foundation.universalapicontract\1.0.0.0\
+   set LIBPATH=%_WKITS10%\UnionMetadata\Facade;%_VS14VC%\vcpackages;;%_WKITS10%\references\windows.foundation.foundationcontract\2.0.0.0\;;%_WKITS10%\references\windows.foundation.universalapicontract\2.0.0.0\
    goto :eof

 :end

I suspect almost the same change will be needed to the WinRT branch.

FYI @sgrebnov (Sergey Grebnov) made an excellent tool for newcomers like myself to build OpenSSL for Windows 8.1 and Windows 10 UWP at: https://github.com/sgrebnov/OpenSSL-WinRT-build

khouzam commented 8 years ago

This is great. Thank you. And thanks for the project pointer.

joycepg commented 6 years ago

just FYI i rebuilt my machine with a new SSD and reinstalled VS2015.3, thus i didn't have any legacy SDKs or older versions. I had to modify ms/setVSvars.bat to v3.0.0.0 of universalapicontract. i'm not sure how you are supposed to tell what is there without poking around in file explorer.

set "LIBPATH=%_WKITS10%UnionMetadata\Facade;%_VS14VC%vcpackages;%_WKITS10%references\windows.foundation.foundationcontract\2.0.0.0\;%_WKITS10%references\windows.foundation.universalapicontract\3.0.0.0\"