gcc/libgm2/libm2iso
Gaius Mulley 63fb0bedb8 PR modula2/110779 SysClock can not read the clock (Darwin portability fixes)
This patch adds corrections to defensively check against glibc functions,
structures and contains fallbacks.  These fixes were required under Darwin.

gcc/m2/ChangeLog:

	PR modula2/110779
	* gm2-libs-iso/SysClock.mod (EpochTime): New procedure.
	(GetClock): Call EpochTime if the C time functions are
	unavailable.
	* gm2-libs-iso/wrapclock.def (istimezone): New function
	definition.

libgm2/ChangeLog:

	PR modula2/110779
	* configure: Regenerate.
	* configure.ac: Provide special case test for Darwin cross
	configuration.
	(GLIBCXX_CONFIGURE): New statement.
	(GLIBCXX_CHECK_GETTIMEOFDAY): New statement.
	(GLIBCXX_ENABLE_LIBSTDCXX_TIME): New statement.
	* libm2iso/wrapclock.cc: New sys/time.h conditional include.
	(sys/syscall.h): Conditional include.
	(unistd.h): Conditional include.
	(GetTimeRealtime): Re-implement.
	(SetTimeRealtime): Re-implement.
	(timezone): Re-implement.
	(istimezone): New function.
	(daylight): Re-implement.
	(isdst): Re-implement.
	(tzname): Re-implement.

Signed-off-by: Gaius Mulley <gaiusmod2@gmail.com>
2023-08-12 18:17:41 +01:00
..
ChanConsts.h
ErrnoCategory.cc PR 109125 Modula2 SIGBUS in m2pim_ldtoa_ldtoa 2023-03-14 19:52:11 +00:00
m2rts.h PR 107630 runtime libs should be self-contained 2023-03-16 20:34:32 +00:00
Makefile.am PR modula2/110779 SysClock can not read the clock 2023-08-05 17:35:12 +01:00
Makefile.in PR modula2/110779 SysClock can not read the clock 2023-08-05 17:35:12 +01:00
RTco.cc Replace bool as boolean instead of int in libgm2 2023-05-13 15:49:50 +01:00
wrapclock.cc PR modula2/110779 SysClock can not read the clock (Darwin portability fixes) 2023-08-12 18:17:41 +01:00
wrapsock.c PR 109125 Modula2 SIGBUS in m2pim_ldtoa_ldtoa 2023-03-14 19:52:11 +00:00
wraptime.cc PR modula2/110779 SysClock can not read the clock 2023-08-05 17:35:12 +01:00