Building on Windows from scratch - difftime problem found ( was datediff )

Derek Atkins warlord at MIT.EDU
Mon Jan 27 11:31:24 EST 2014

John Ralls <jralls at> writes:

>> Hold on though.  These solutions don't call MSVCRT at all, so why
>> does that matter?  And if it did, why would your solution work
>> anyway, given that sizeof is evaluated at compile time? (leaving
>> aside Derek's point that it might not compile cleanly.

They are calling MSVCRT indirectly through calls in e.g. libofx.  The
problem is that our generally-compiled code might wind up calling the
"wrong" underlying API and therefore getting bogus data back.  Part of
the issue is that we build on XP which doesn't know about the 32/64
dichotomy.  That was introduced in Vista, IIRC.

> It looks to me that always defining _USE_32_BIT_TIME_T might work,
> though you might have to make that conditional on Vista-or-later. Have
> you tested that?
> Regards,
> John Ralls


       Derek Atkins, SB '93 MIT EE, SM '95 MIT Media Laboratory
       Member, MIT Student Information Processing Board  (SIPB)
       URL:    PP-ASEL-IA     N1NWH
       warlord at MIT.EDU                        PGP key available

More information about the gnucash-devel mailing list