C++ 链接:致命错误 LNK1104:无法打开文件“glut32.lib”。如何修复这个错误?

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/17583523/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-27 21:17:36  来源:igfitidea点击:

LINK : fatal error LNK1104: cannot open file "glut32.lib". how to fix this error?

c++visual-c++compiler-errors

提问by user2570637

I want to ask a question. I'm using Microsoft Visual Studio 6.0 and I was stuck in this #error. LINK : fatal error LNK1104: cannot open file "glut32.lib". Actually the command that I used can be run at my computer lab at my college but now I'm using my pc's to run it. I already follow the step to install openGL in my pc's, but it is still stuck. I hope somebody can help me. Thanks.

我想问个问题。我正在使用 Microsoft Visual Studio 6.0 并且我被困在这个 #error 中。LINK : fatal error LNK1104: cannot open file "glut32.lib". 实际上,我使用的命令可以在我大学的计算机实验室中运行,但现在我正在使用我的电脑来运行它。我已经按照步骤在我的电脑上安装了 openGL,但它仍然卡住了。我希望有人可以帮助我。谢谢。

回答by Manas

Check your VC\libfolder, is there a file called glut32.lib? If not, re-download GLUT and follow the README to put files in the right folder. Here is a link to GLUT

检查您的VC\lib文件夹,是否有名为 glut32.lib 的文件?如果没有,请重新下载 GLUT 并按照自述文件将文件放在正确的文件夹中。这是GLUT的链接

回答by KHV

C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\lib

C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\lib

This path is for VS 2013, depending on the Visual Studio Version 11.0/12.0 will be varied

此路径适用于 VS 2013,根据 Visual Studio 版本 11.0/12.0 会有所不同

回答by Jungro

Copy "glut32.lib" to "C:\Program Files (x86)\Windows Kits\8.1\Lib\winv6.3\um\x86".

将“glut32.lib”复制到“C:\Program Files (x86)\Windows Kits\8.1\Lib\winv6.3\um\x86”。