公司的产品有两个版本,一个用vs2005编译,一个用vc6编译。
新增了个功能,用vs2005编译后没问题,用vc6编译的就不好使。我的机器上没有装vc6,所以装vc6调试。
装完后编译出现以下问题:
NOTE: WINVER has been defined as 0x0500 or greater which enables
Windows NT 5.0 and Windows 98 features. When these headers were released,
Windows NT 5.0 beta 1 and Windows 98 beta 2.1 were the current versions.
For this release when WINVER is defined as 0x0500 or greater, you can only
build beta or test applications. To build a retail application,
set WINVER to 0x0400 or visit http://www.microsoft.com/msdn/sdk
to see if retail Windows NT 5.0 or Windows 98 headers are available.
See the SDK release notes for more information.
一番google,原来是SDK没有更新。
然后更新SDK,给vc6打补丁。
然后继续编译,出现头文件找不到。添加环境变量,解决之。
新添加的环境变量只对新建的进程有效,所以必须重启vc6才好使。