[ntp:questions] p351 fails to build on MSVC++2008EE

Charles Swiger cswiger at mac.com
Fri Jan 25 17:30:31 UTC 2013

Hi, Martin--

On Jan 25, 2013, at 5:23 AM, Martin Burnicki <martin.burnicki at meinberg.de> wrote:
> Chuck Swiger wrote:
>> On 24/01/2013 12:52, Mischanko, Edward T wrote:
>>> I thought we were going to fix this?
>>> c:\3\ntp-dev-4.2.7p351\sntp\libopts\option-xat-attribute.h(38)
>>>  : fatal error C1083: Cannot open include file: 'inttypes.h'
>>> : No such file or directory
>>> Are we still working on this?
>> David's suggestion to adjust the includes is the autoconf-style change;
>> anyway, I'm not sure that many Windows boxes have a sufficiently
>> POSIX-compliant shell to run ./configure without installing Cygwin or similar.
>> As an alternative, there's an inttypes.h for MSVC here:
>>   http://msinttypes.googlecode.com/svn/trunk/inttypes.h
> It would be pretty easy to fix this directly in the NTP source code.
> However, IMO adding a "proprietary" inttypes.h to the NTP source is going to cause confusion if we'd start to support cygwin, mingw or whatever to build NTP under Windows.

I see your point, but I wasn't suggesting adding anything to NTP's source code.

It's 2013; it's entirely reasonable to expect C99 aka ISO/IEC 9899:1999 standard headers to be provided by the OS / compiler toolchain.  Rumor suggests that sufficiently modern versions of MSVC might fix this, but if not, I do recall that building ntpd under Cygwin worked OK using the GNU toolchain instead.

> Those environmenrts come with their own inttypes.h, and if there is a special NTP version of this file for Windows it depends on the sequence of header search paths which of the files would be found at first.

Sure, I agree: let's not add a special NTP version of a standard header.  :-)


More information about the questions mailing list