简体   繁体   English

Visual Studio 2010:dll丢失

[英]Visual Studio 2010: dll missing

I googled for a whole day and I'm goin' mad.. 我用谷歌搜索了一整天,我疯了

Well, that's my problem: I've written my vs project, I've specified all the "include" (by selecting project properties -> configuration properties -> VC++ directories) and all the extern libraries directories (in the same way). 嗯,这是我的问题:我编写了我的vs项目,我已经指定了所有的“include”(通过选择项目属性 - >配置属性 - > VC ++目录)和所有extern库目录(以相同的方式)。 Then I specified all the additional libraries by selecting project properties -> Linker -> input -> Additional Dependencies and adding all the .lib files paths. 然后我通过选择项目属性 - >链接器 - >输入 - >附加依赖项并添加所有.lib文件路径来指定所有其他库。 I press F7, it compiles with no errors. 我按F7,它编译没有错误。 I run the project and.. System Error: libsndfile-1.dll is missing. 我运行该项目和..系统错误:缺少libsndfile-1.dll。

That's okay, so I opened the vs console, I moved to libsndfile-1.def (and libsndfile-1.lib) path and I executed: "lib.exe libsndfile.def". 没关系,所以我打开了vs控制台,我转到了libsndfile-1.def(和libsndfile-1.lib)路径,我执行了:“lib.exe libsndfile.def”。 Here I got another error: "LINK: fatal error lnk1104 lib.exe, impossible to open libsndfile.lib" 在这里我得到另一个错误:“LINK:致命错误lnk1104 lib.exe,无法打开libsndfile.lib”

I tried to download libsndfile.dll from web but it still don't works. 我试图从网上下载libsndfile.dll,但它仍然无法正常工作。 I've also tried to put all the libraries in my source files in visual studio.. but again, no way. 我也尝试将所有库放在我的源文件中的Visual Studio中..但是再一次,没办法。

Where am I wrong? 我哪里错了?

Thank you in advance 先感谢您

EDIT: I've seen that vs doesn't find the other dll also! 编辑:我见过vs没有找到其他的dll!

Please do not copy the DLL into the folder... this is annoying for other developers in your organisation; 请不要将DLL复制到文件夹中...这对您组织中的其他开发人员来说很烦人; instead right-click your app and click properties, go into the Configuration Properties->Debugging and set the Environment value to: 而是右键单击您的应用程序并单击属性,进入配置属性 - >调试并将环境值设置为:

PATH=C:\PathToInclude;%PATH%

this will add the path to your environment and merge it to your application environment. 这将添加环境路径并将其合并到您的应用程序环境中。

Do that for all Configurations of your app. 为您的应用的所有配置执行此操作。

我解决了简单地将所有dll文件放在.exe文件的同一目录中

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM