GnuPG 1.4.4 build error on mingw/msys when using mingw-runtime-3.10
jvender at owensboro.net
Mon Jun 26 13:05:55 CEST 2006
After upgrading mingw-runtime on my mingw/msys build environment to
mingw-runtime-3.10 from 3.9, I experience a build error when trying to
compile the GnuPG 1.4.4 source code. I receive the error in random.c at:
#include <sys/times.h> <-------
complaining that it can't find <sys/times.h>, resulting in other errors
and an abort.
Reading from the changelog for mingw-runtime-3.10 at
"* include/sys/time.h: Add header guard. Add extern "C" bracketing
(gettimeofday): Add prototype.
* mingwex/gettimeofday.c: New file.
* mingwex/makefile.in: Add gettimeofday source and object."
Apparently, the "gettimeofday" prototype was introduced in
mingw-runtime-3.10, but it's located in <sys/time.h>,
not in <sys/times.h>. Indeed, I have no <sys/times.h>
This causes the compilation attempt to abort.
Since gettimeofday wasn't being #defined for me prior to this version of
mingw-runtime, I didn't see this error prior to now. Is this simply a
typo, or is there an inconsistency, between platforms, in naming
conventions for the header files regarding where the prototypes are
defined? Simply changing <sys/times.h> to <sys/time.h> resulted in a
successful compile and passing of all 27 "make check" tests.
More information about the Gnupg-devel