使用VS2019创建C语言动态库
总体步骤和创建静态库没有什么区别,需要注意的是创建动态库时,需要在库的任意一个头文件xx.h中添加__declspec(dllexport),具体请查看dllexport、dllimport
需要手动填写依赖项和附加库目录:


其他就和创建静态库没有什么区别了
请参考:https://www.geek-share.com/detail/2795072563.html
https://docs.microsoft.com/zh-cn/cpp/build/walkthrough-creating-and-using-a-dynamic-link-library-cpp?view=msvc-160
评论已关闭