肯肯

DNN, DotNetNuke, CS, CCS, ANF, Oracle, GIS, RIA, JS, XML, AJAX

  博客园 :: 首页 :: 博问 :: 闪存 :: 新随笔 :: 联系 :: 订阅 订阅 :: 管理 ::

在 VS2008 下编译c++程序,发现找不到 stdint.h, 最后证实原因如下红字,解决方案是改用符合C99标准的编译器(如VS2010),或自定义头文件:

 

#ifdef _MSC_VER  
typedef __int32 int32_t; 
typedef unsigned __int32 uint32_t; 
typedef __int64 int64_t; 
typedef unsigned __int64 uint64_t;  
#else 
#include <stdint.h> 
#endif 

  

Visual Studio 2003 - 2008 (Visual C++ 7.1 - 9) don't claim to be C99 compatible

 

另注:在VS2010下,stdint.h 的位置在 C:\Program Files\Microsoft Visual Studio 10.0\VC\include

posted on 2012-04-22 22:14  verygis  阅读(27930)  评论(1编辑  收藏  举报