Error LNK2001: unresolved external symbol __imp_SetTrialKey on windows using cython

Hi, I use Cython to wrap the library because our App is implemented in Python. On the Windows platform, I have installed VS2015 community and added the extra objects LexActivator.lib and libcurl_MD.lib. I also add #define LEXACTIVATOR__STATIC on the top of the header file. But still failed to compile with Cython. Every declared function cannot be linked.

error LNK2001: unresolved external symbol __imp_SetTrialKey

I do not know why? Any ideas?

Hi,

Can you try linking the dynamic library instead of the static library. Static library is only meant for c/c++ applications.