1

I am relatively new to Win32 native programming. I have written a small C library for Windows. It uses functions from PolarSSL. PolarSSL is an open source library currently distributed with a VC++ .sln file, which can be built and generates a static .lib file.

Originally, my library was built as a static .lib too, and programs which want to make use of it have to link PolarSSL and my library. Both libraries are written in C (not C++).

Now I need to convert my library to a .dll. I can easily change my code to export functions and recompile as a .dll, but I wanted to know if I can leave the PolarSSL .lib file untouched. The application will not need functions from PolarSSL, but it will use functions from my library. I want to convert it to .dll because I want to call my functions from a Mozilla Firefox add on (using js-ctypes).

So, can I link the static .lib PolarSSL lib into my .dll library and only export functions from my .dll?

Thanks!

4

1 回答 1

3

是的,这是完全可能的。然后,您将拥有包含在您的 DLL 中的 PolarSSL 的完整副本,而没有任何由 DLL 公开的静态库。

于 2013-09-03T22:26:46.630 回答