我试图在我的C++应用程序中使用#include <openssl/hmac.h>
。因此,我尝试遵循以下说明:
http://www.askyb.com/windows/compiling-and-installing-openssl-for-32-bit-windows/comment-page-1/#comment-47532
我成功做到了这一点:
C:\openssl-1.0.1c
C:\perl\bin
添加到了我的路径中-http://i.imgur.com/QOhKUwl.png C:\openssl-1.0.1c-bin
cmd
"C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\Tools\vsvars32.bat"
(这是正确的路径),它存在于我的系统中perl Configure VC-WIN32 no-asm – -prefix=C:\openssl-1.0.1c-bin
(没有引号),它告诉我ppm install dmake
来获取nmake
,所以我做到了-http://i.imgur.com/SuC65oo.png nmake
-https://github.com/curl/curl/issues/1002-不再可以执行nmake -f ms\ntdll.mak
,这大约需要15分钟的时间nmake test
通过了所有测试,但是我的
C:\openssl-1.0.1c-bin
目录为空,并且执行#include <openssl/hmac.h>
无法在我的Visual Studio中工作。我是写C++的新手。
谢谢
最佳答案
您错过了最后一个步骤,运行此命令“nmake -f ms \ ntdll.mak install”。它将所有库复制到C:\ openssl-1.0.1g-bin。
如果这样做,它将按预期工作。我只是在Windows 7和Visual Studio 2015中在本地尝试过,效果很好。
关于nmake的警告是虚假的,您可以继续使用nmake ok。
关于c++ - Visual Studio 2015 OpenSSL,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/41357374/