Difficulty building on MacOSX

Mike Alexander mta at umich.edu
Thu May 7 16:58:47 EDT 2015

--On May 7, 2015 at 7:19:49 AM -0700 John Ralls <jralls at ceridwen.us> 

> Surely you didn’t rebuild libc just to get a 64-bit time_t. What
> motivated you? Since you went to the work of replacing libc and the
> headers in your SDK (and have to redo it every time Apple pushes an
> Xcode upgrade), why not upgrade your TZ database as well?

No, I didn't rebuild libc or anything like that.

When I compile gnc-timezone.cpp the command used is

clang++ -DHAVE_CONFIG_H -I. -I../../../../../gnucash/src/libqof/qof 
-I../../.. -I../../../../../gnucash/lib/libc 
-I../../../../../gnucash/src -D_REENTRANT -I/opt/local/include/glib-2.0 
-I/opt/local/lib/glib-2.0/include -I/opt/local/include 
-I/opt/local/include -DG_LOG_DOMAIN=\"qof\" -I/opt/local/include 
-DDUMP_FUNCTIONS -Werror -Wall -Wno-unused -Wno-deprecated-register 
-std=gnu++11 -g -O0 -MT gnc-timezone.lo -MD -MP -MF 
.deps/gnc-timezone.Tpo -c 
../../../../../gnucash/src/libqof/qof/gnc-timezone.cpp  -fno-common 
-DPIC -o .libs/gnc-timezone.o

In this compilation, time_t is defined in 
/usr/include/sys/_types/_time_t.h as

   typedef __darwin_time_t time_t;

__darwin_time_t is defined in /usr/include/i386/_types.h as

   typedef long __darwin_time_t;

I'm using

Apple LLVM version 6.1.0 (clang-602.0.49) (based on LLVM 3.6.0svn)
Target: x86_64-apple-darwin14.3.0
Thread model: posix

to compile this.   It's located in /usr/bin/clang++.

In that compilation sizeof(long) is 8.

/etc/localtime is a symlink to /usr/share/zoneinfo/America/Detroit 
which was last changed on Nov. 16.  I've never touched that file, or 
either of the include files, myself.  I don't know why my machine is 
different from yours.


More information about the gnucash-devel mailing list