如何从 cl.exe 命令行向 dll (advapi32.dll) 添加静态依赖项? [英] How do I add a static dependency to a dll (advapi32.dll) from the cl.exe command line?

查看:30
本文介绍了如何从 cl.exe 命令行向 dll (advapi32.dll) 添加静态依赖项?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我确定我遗漏了一些简单的东西.我正在从 Visual Studio 命令提示符运行.

I'm sure there's something simple I'm missing. I'm running from the Visual Studio Command Prompt.

推荐答案

通过链接正确的导入库.

By linking with the right import library.

将 advapi32.lib 添加到命令行,cl.exe 应将其识别为要链接的库.

Add advapi32.lib to the command line, cl.exe should recognize it as a library to link to.

这篇关于如何从 cl.exe 命令行向 dll (advapi32.dll) 添加静态依赖项?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆