Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Dynamic linking in Visual Studio

I have to link dynamically with OpenSSL libeay32.dll. I'm writing native c++ console application using Visual C++ Express 2008.

I'm including a header evp.h from OpenSSL distribution. Building and...:

error LNK2001: unresolved external symbol _EVP_aes_256_cbc
error LNK2001: unresolved external symbol _EVP_DecryptInit
error LNK2001: unresolved external symbol _EVP_CIPHER_CTX_init

How to make calls to libeay32.dll methods? I don't know where to specify it's filename

like image 901
ILya Avatar asked Nov 23 '25 15:11

ILya


2 Answers

There is probably a .lib file you also need to add to your compiler's linker input. Check the documentation for the library you're using.

like image 89
AshleysBrain Avatar answered Nov 26 '25 04:11

AshleysBrain


Try using Win32 API's LoadLibrary function, the following link might be of some help :example

like image 25
rsjethani Avatar answered Nov 26 '25 05:11

rsjethani



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!