【发布时间】:2016-01-20 21:02:52
【问题描述】:
我正在使用 MSVC 2015 64 位命令提示符从源代码构建 GDAL。我使用的是 Windows 8。在构建过程中,我收到以下错误:
Creating library gdal_i.lib and object gdal_i.exp
odbccp32.lib(dllload.obj) : error LNK2019: unresolved external symbol _vsnwprintf_s referenced in function StringCchPrintfW
gdal201.dll : fatal error LNK1120: 1 unresolved externals
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\BIN\amd64\link.EXE"' : return code '0x460'
Stop.
我在 Microsoft 站点和 GDAL Git 问题部分阅读到,这是 2014 MSVC 和 MSVC 2015 的预发布版本的问题,但该问题应该在 MSVC 2015 的最终版本之前得到解决。
- https://github.com/mapbox/windows-builds/issues/53
- https://connect.microsoft.com/VisualStudio/feedback/details/1134693/vs-2015-ctp-5-c-vsnwprintf-s-and-other-functions-are-not-exported-in-appcrt140-dll-breaking-linkage-of-static-libraries
我似乎不是唯一遇到此问题的人,但我也没有看到解决方案(除了恢复到 MSVC 的旧版本,例如 2013)。有没有人有幸让 GDAL 使用 MSVC 2015(64 位)构建?
【问题讨论】:
标签: c++ visual-c++ visual-studio-2015 gdal nmake