[英]Linking errors when trying to build GLFW
I'm using CMAKE to build GLFW, but its spewing out the following error: No CMAKE_C_COMPILER could be found.
我正在使用CMAKE构建GLFW,但它喷出了以下错误:
No CMAKE_C_COMPILER could be found.
. 。 This is the entire output log, though i think the important bit is:
这是整个输出日志,尽管我认为重要的一点是:
LINK : fatal error LNK1104: cannot open file 'ucrtd.lib'
链接:致命错误LNK1104:无法打开文件'ucrtd.lib'
I've done some searching and it seems like my Visual Studio installation is fried, when i try to repair it i get a ton of errors about packages that cannot be found. 我进行了一些搜索,似乎我的Visual Studio安装被炸了,当我尝试对其进行修复时,我遇到了大量无法找到的错误包。 I've tried to reinstall some C++ redist and the Windows 7 SDK, though that didnt fix it.
我试图重新安装一些C ++ redist和Windows 7 SDK,尽管那没有解决。
Update: 更新:
You need to specify the generator when running cmake, if you use VS2013: 如果使用VS2013,则在运行cmake时需要指定生成器:
cmake . -G "Visual Studio 12 2013 Win64"
For Visual Studio 2015 it should be 对于Visual Studio 2015,应为
cmake . -G "Visual Studio 14 2015 Win64"
Here is the complete list of generators. 这是发电机的完整列表。 Maybe you have to leave out the "Win64" part.
也许您必须省略“ Win64”部分。
Original post: 原始帖子:
According to 根据
https://connect.microsoft.com/VisualStudio/feedback/details/1160492/linker-errors-after-upgrading-from-ctp5-to-ctp6 https://connect.microsoft.com/VisualStudio/feedback/details/1160492/linker-errors-after-upgrading-from-ctp5-to-ctp6
you could try to add $UniversalCRT_LibraryPath to Configuration Properties -> VC++Directories -> Library Directories. 您可以尝试将$ UniversalCRT_LibraryPath添加到配置属性-> VC ++ Directories->库目录。 Does this solve your problem?
这样可以解决您的问题吗?
One thing you could also try is to uninstall and then reinstall MSVC. 您还可以尝试的一件事是先卸载再重新安装MSVC。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.