newlib-cygwin/newlib/libc/include
Hans-Peter Nilsson 571e730678 Complete revert of 2019-08-19, st_atime in libc/include/sys/stat.h
The revert-part of the revert-and-fix commit, b99887c428 a.k.a.
"Revert previous change to sys/stat.h and fix cris libgloss",
apparently intending to revert f75aa67851 a.k.a. "Fix regression in
cris-elf caused by sys/stat.h change" and fix it in another way,
wasn't complete.  Although the fix-part added the prerequisite "#undef
st_atime" (et al) to gensyscalls, the revert-part didn't revert the
"&& !defined(__cris__)" in sys/stat.h, stopping st_atime (et al) from
being defined.

The effect of the unreverted change is that accessing the struct stat
compatibility member names "st_atime" (et al) as in "struct stat
mystat; mystat.st_atime;" yields errors, observable for example when
building libgfortran in gcc:

/x/gcc/libgfortran/intrinsics/stat.c:114:42: error: 'struct stat' has \
no member named 'st_atime'; did you mean 'st_atim'?
  114 |       sarray->base_addr[8 * stride] = sb.st_atime;
      |                                          ^~~~~~~~
      |                                          st_atim
(etc.)

Trivially fixed by completing the reversion, removing the "&&
!defined(__cris__)" in sys/stat.h.

Beware: the net effect of the earlier related change to struct stat in
sys/stat.h, leading up to the fix, *does* change its definition as a
type.  Thankfully, replacing members like "time_t st_atime; long
st_spare1;" by "struct timespec st_atim;", ditto st_mtim and st_ctim,
is layout-compatible.  To wit, that change is "binary compatible".

Incidentally, related to the simulator / Linux ABI, there's a
transitional stage (see gensyscalls), reloading between "struct stat"
(sys/stat.h) and "struct new_stat" (kernel/simulator) as necessary.

Tested by a cris-elf gcc build (including libgfortran).
2021-02-16 13:57:11 +01:00
..
machine Port of C-SKY for newlib 2020-09-23 15:08:59 -04:00
rpc ansification: remove _EXFUN, _EXFUN_NOTHROW 2018-01-17 11:47:29 -06:00
ssp ssp: fix wchar.h with -std=c99 2018-03-14 10:46:32 -05:00
sys Complete revert of 2019-08-19, st_atime in libc/include/sys/stat.h 2021-02-16 13:57:11 +01:00
_ansi.h ansification: remove _HAVE_STDC 2018-01-17 11:47:30 -06:00
_newlib_version.h Fix _newlib_version.h logic to support building gcc with newlib. 2016-02-25 15:04:19 -05:00
_syslist.h 2009-12-17 Jeff Johnston <jjohnstn@redhat.com> 2009-12-17 21:08:04 +00:00
alloca.h ansification: remove _EXFUN, _EXFUN_NOTHROW 2018-01-17 11:47:29 -06:00
ar.h Use remove-advertising-clause script to edit BSD licenses 2020-01-29 19:03:31 +01:00
argz.h
assert.h ansification: remove _EXFUN, _EXFUN_NOTHROW 2018-01-17 11:47:29 -06:00
complex.h Fixed warnings for some long double complex methods 2017-07-05 14:40:02 +02:00
cpio.h Add cpio.h 2016-04-04 10:25:27 -05:00
ctype.h Fix return type of __locale_ctype_ptr_l() 2020-11-16 19:34:30 +01:00
devctl.h libc/include/newlib.h: Fix C++ compilation issue 2020-11-16 08:15:18 -06:00
dirent.h Move common <sys/dirent.h> content to <dirent.h> 2018-10-11 08:29:16 +02:00
elf.h Add the Aarch64 SVE specific HWCAP_SVE define 2017-11-22 14:10:37 -05:00
envlock.h ansification: remove _EXFUN, _EXFUN_NOTHROW 2018-01-17 11:47:29 -06:00
envz.h
errno.h
fastmath.h
fcntl.h
fenv.h Add default implementation of fenv.h and all methods 2019-08-09 17:49:16 +02:00
fnmatch.h Feature test macros overhaul: fnmatch.h 2016-03-17 21:08:54 -05:00
ftw.h FTW Port for Newlib 2021-02-09 11:07:59 +01:00
getopt.h newlib: getopt now permutes multi-flag options correctly 2018-06-18 18:45:44 +02:00
glob.h 2013-11-21 Julio Gutierrez <jgutleyva@gmail.com> 2013-11-21 17:04:57 +00:00
grp.h Use remove-advertising-clause script to edit BSD licenses 2020-01-29 19:03:31 +01:00
iconv.h ansification: remove _EXFUN, _EXFUN_NOTHROW 2018-01-17 11:47:29 -06:00
ieeefp.h ansification: remove _EXFUN, _EXFUN_NOTHROW 2018-01-17 11:47:29 -06:00
inttypes.h libc/include/inttypes.h: Remove parameter name 2020-10-02 17:00:43 -04:00
langinfo.h Rename <xlocale.h> back to <sys/_locale.h> 2019-06-14 10:02:08 +02:00
libgen.h ansification: remove _EXFUN, _EXFUN_NOTHROW 2018-01-17 11:47:29 -06:00
limits.h Include sys/syslimits.h in limits.h 2018-09-06 14:11:45 +02:00
locale.h Rename <xlocale.h> back to <sys/_locale.h> 2019-06-14 10:02:08 +02:00
malloc.h Add prototype to _malloc_lock() and *unlock() to malloc.h, and inlude this from nano-mallocr.c 2018-02-16 12:16:07 +01:00
math.h libc/include/math.h: Remove parameter name 2020-09-25 22:53:43 -04:00
memory.h Provide <memory.h> 2016-11-22 14:21:35 +01:00
ndbm.h Port ndbm - Remove Declaration of dbm_forder 2019-07-25 15:28:32 +02:00
newlib.h
paths.h 2013-10-10 Sebastian Huber <sebastian.huber@embedded-brains.de> 2013-10-15 17:34:23 +00:00
pthread.h Correct prototypes of pthread_mutex_getprioceiling() and pthread_setschedparam() 2018-03-15 09:25:45 -05:00
pwd.h Use remove-advertising-clause script to edit BSD licenses 2020-01-29 19:03:31 +01:00
reent.h ansification: remove _PARAMS 2018-01-17 11:47:13 -06:00
regdef.h
regex.h 2013-11-20 Chirayu Desai <chirayudesai1@gmail.com> 2013-11-20 16:25:50 +00:00
sched.h sched.h: Declare affinity functions only on targets supporting them 2019-08-12 17:30:20 +02:00
search.h 2013-11-20 Daniel Ramirez <javamonn@gmail.com> 2013-11-20 18:22:27 +00:00
setjmp.h ansification: remove _EXFUN, _EXFUN_NOTHROW 2018-01-17 11:47:29 -06:00
signal.h ansification: remove _EXFUN, _EXFUN_NOTHROW 2018-01-17 11:47:29 -06:00
spawn.h ansification: remove _EXFUN, _EXFUN_NOTHROW 2018-01-17 11:47:29 -06:00
stdatomic.h sys: clean up empty lines in .c and .h files 2020-10-26 14:18:46 +01:00
stdint.h Provide __intmax_t and __uintmax_t 2016-10-25 16:24:05 +02:00
stdio.h Use remove-advertising-clause script to edit BSD licenses 2020-01-29 19:03:31 +01:00
stdio_ext.h ansification: remove _EXFUN, _EXFUN_NOTHROW 2018-01-17 11:47:29 -06:00
stdlib.h Rename <xlocale.h> back to <sys/_locale.h> 2019-06-14 10:02:08 +02:00
string.h Rename <xlocale.h> back to <sys/_locale.h> 2019-06-14 10:02:08 +02:00
strings.h Rename <xlocale.h> back to <sys/_locale.h> 2019-06-14 10:02:08 +02:00
tar.h Feature test macros overhaul: tar.h 2016-04-04 10:25:29 -05:00
termios.h
tgmath.h Add missing long double functions to Cygwin 2016-03-29 14:43:55 +02:00
threads.h Import <threads.h> from latest FreeBSD. 2015-10-13 17:52:34 -04:00
time.h libc/time: Move internal newlib tz-structs into own header 2020-10-15 16:59:51 +02:00
unctrl.h Use remove-advertising-clause script to edit BSD licenses 2020-01-29 19:03:31 +01:00
unistd.h
utime.h
utmp.h
wchar.h libc/include/wchar.h: Remove parameter name 2020-10-02 17:02:28 -04:00
wctype.h Rename <xlocale.h> back to <sys/_locale.h> 2019-06-14 10:02:08 +02:00
wordexp.h 2013-11-23 Bryan Dunsmore <dunsmoreb@gmail.com> 2013-11-23 22:39:34 +00:00