configure for universal build fails on OS X
Brought to you by:
guidod
When trying to perform a universal build on OS X 10.7.3, configure fails:
LDFLAGS="-arch i386 -arch x86_64" CFLAGS="-arch i386 -arch x86_64" ./configure --prefix=/usr/local --disable-dependency-tracking
...
checking size of long... configure: error: cannot determine a size for long
See attached log file for details.
Configure log file
macports (and soon homebrew likely) are using this workaround:
ac_cv_sizeof_long="(LONG_BIT/8)" LDFLAGS="-arch i386 -arch x86_64" CFLAGS="-arch i386 -arch x86_64" ./configure --prefix=/usr/local --disable-dependency-tracking
...
Note the ac_cv_sizeof_long override.