Vista / Win 7 SDK bufferoverflowu.lib linking error
I downloaded the Windows SDK 7.0A to explore some things I was reading about. I downloaded some samples that work 开发者_StackOverflow中文版with the SDK but when I try to compile them I get an error. I looked in the Lib directory of the SDK and couldn't find it. I also did a full system search and also did not find it.
I have read about this being a special link added at compile or the result of a version check in a pragma. I could not find any reference to the lib in the source or all the header files.
I'm running:
Vista Ultimate VS 2010 Beta 2 Microsoft Windows SDK for Windows 7 and .NET Framework 3.5 Service Pack 1My Error:
error LNK1104: cannot open file 'bufferoverflowu.lib'
I just reinstalled and am still getting the same issue.
What sample exactly are you trying to build - a little research shows that the bufferoverflowu.lib
(and other related bufferoverflow*.lib
files) were in previous SDKs to support building with compilers from before and after Microsoft added the ability for the compiler to generate buffer overflow checks (starting with the /GS option in VS 2003 - I think).
The libraries were in the SDK so that if the user built a Windows program with compiler that didn't support the buffer overflow checks, the SDK libraries that had been built that way would link to the code in the bufferoverflow*.lib
to get the support. If the user was building with a newer compiler, everything would link to the C runtime library that had the buffer overflow support.
However, the Windows SDK v7.0 only supports building applications with VS 2005 SP1 or newer, so the buffer overflow checking code always comes from the C runtime - the bufferoverflow*.lib
file should no longer be necessary.
精彩评论