diff options
author | Christian Biesinger <cbiesinger@google.com> | 2019-11-08 11:25:17 -0600 |
---|---|---|
committer | Christian Biesinger <cbiesinger@google.com> | 2019-11-15 11:48:08 -0800 |
commit | f8e27d88e4c31089467d8717597c4153723081e6 (patch) | |
tree | 84708cf16eef4f4c3108b527622833ae1e227781 /gdb/gdbsupport | |
parent | 5abebf3c3fd28a148e43be587c4e4065a0e53ae9 (diff) | |
download | gdb-f8e27d88e4c31089467d8717597c4153723081e6.zip gdb-f8e27d88e4c31089467d8717597c4153723081e6.tar.gz gdb-f8e27d88e4c31089467d8717597c4153723081e6.tar.bz2 |
Import the time_r gnulib module
This allows GDB to use localtime_r unconditionally.
See https://lists.gnu.org/archive/html/bug-gnulib/2019-11/msg00022.html
for details on the compile error mentioned below.
gdb/ChangeLog:
2019-11-15 Christian Biesinger <cbiesinger@google.com>
* gdbsupport/common-defs.h: Include time.h before pathmax.h to
avoid compile errors.
gnulib/ChangeLog:
2019-11-15 Christian Biesinger <cbiesinger@google.com>
* Makefile.in: Regenerate.
* aclocal.m4: Regenerate.
* config.in: Regenerate.
* configure: Regenerate.
* import/Makefile.am: Update.
* import/Makefile.in: Regenerate.
* import/m4/gnulib-cache.m4: Update.
* import/m4/gnulib-comp.m4: Update.
* import/m4/time_r.m4: New file.
* import/time_r.c: New file.
* update-gnulib.sh: Import time_r.
Change-Id: I53fc861b192940d613ca97f2910b4533c730f667
Diffstat (limited to 'gdb/gdbsupport')
-rw-r--r-- | gdb/gdbsupport/common-defs.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/gdb/gdbsupport/common-defs.h b/gdb/gdbsupport/common-defs.h index 203bd89..3b10468 100644 --- a/gdb/gdbsupport/common-defs.h +++ b/gdb/gdbsupport/common-defs.h @@ -97,6 +97,11 @@ #endif #include <errno.h> #include <alloca.h> +/* Must be included before pathmax.h to avoid build errors about localtime_r + and gmtime_r in gnulib on MinGW. This is a gnulib bug: + https://lists.gnu.org/archive/html/bug-gnulib/2019-11/msg00022.html */ +#include <time.h> + #include "ansidecl.h" /* This is defined by ansidecl.h, but we prefer gnulib's version. On |