创建包含所有依赖项的独立DLL
Creating a standalone DLL that contains all dependencies
我正在VS9中的c++项目中工作,该项目引用了许多头文件,.dll和.lib文件。
我想将其作为包含所有依赖项的独立DLL输出,以便我可以使用LoadLibrary()将其拉入。
这是可能的吗?如果是,我如何在VS9中做到这一点?
我已经创建了DLL,但是通过depends.exe运行它会给我错误:
Error: At least one required implicit or forwarded dependency was not found.
Warning: At least one delay-load dependency module was not found.
Warning: At least one module has an unresolved import due to a missing export function in a delay-load dependent module.
谢谢
如果其他dll恰好是CRT,使用/MT编译将消除依赖关系。如果您正在处理其他dll,则可以将它们作为资源嵌入,然后在运行时加载它们。我自己从来没有这样做过,但你可以通过阅读:
- 在Win32可执行文件中嵌入DLL和二进制文件
- 从内存中的某个位置加载DLL
相关文章:
- 挂起和取消挂起一个文件DLL
- 如何使用OpenCV将RBG图像转换为HSV,并将H、S和V值保存为C++中的3个独立图像
- std::threads可以从Windows DLL中的全局变量创建/销毁吗?
- 导入库可以跨dll版本工作吗
- 从C++dll访问C#中的一行主要参数
- 链接到自行创建的dll失败
- 为什么使用 P/Invoke 调用 dll 时,某些计算机中的 LoadLibrary 失败?
- 独立读取-修改-写入顺序
- 在调用FreeLibrary后,释放动态链接到具有相同版本的CRT堆的DLL的内存
- 如何指定我希望我的LIB链接到的DLL文件?-Visual Studio 2019
- 如何将图像传输到c++(dll)中的缓冲区,然后在c#的缓冲区中读/写
- C++:将外部库链接到dll库
- 应用程序仅在qt调试器中加载dll,而不是独立加载
- PlayFunction在DLL中不起作用,但在独立的exe中工作
- Visual Studio 2015 C++ 将独立的 DLL 文件添加到项目中
- 独立 DLL 之间的内部进程通信
- 如何将visual studio 2010解决方案构建为独立的dll
- 两个独立的Qt应用程序可以使用相同的DLL文件吗?
- 创建包含所有依赖项的独立DLL
- 一个独立的DLL如何发现将使用哪些Token文件进行访问