C99 stdint.h header and MS Visual Studio

Solution 1:

Turns out you can download a MS version of this header from:

https://github.com/mattn/gntp-send/blob/master/include/msinttypes/stdint.h

A portable one can be found here:

http://www.azillionmonkeys.com/qed/pstdint.h

Thanks to the Software Ramblings blog.

Solution 2:

Just define them yourself.

#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

Solution 3:

Update: Visual Studio 2010 and Visual C++ 2010 Express both have stdint.h. It can be found in C:\Program Files\Microsoft Visual Studio 10.0\VC\include