Visual Studio error: LNK1104: cannot open file 'kernel32.lib' - only in WP8 projects / Win32 builds

限于喜欢 提交于 2019-11-29 07:27:47

Finally, I have found the reason of my problems: as I suspected, internal Visual Studio configuration has been broken.

I did all standard steps, that can be performed in case of LNK1104, however:

- kernel32.lib was in valid location
- all include and library directories was correct
- standard *.props files were attached to each project

However, the cause was lying elsewhere.

All paths are defined using standard macros. One of them is $(WindowsSDK80Path), which is used to build include/library paths. On my system, this macro was defined as

C:\Program Files (x86)\Windows Phone Kits\8.0

instead of

C:\Program Files (x86)\Windows Kits\8.0

And that's it. I do not know, when or how, this problem arosed. Visual Studio repair via orginal installer was sufficient method to fix everything. All projects compile now without any problems.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!