This is the mail archive of the
newlib@sourceware.org
mailing list for the newlib project.
_DIRENT_HAVE_D_RECLEN ignored by readdir
- From: Giacomo Tesio <giacomo at tesio dot it>
- To: newlib at sourceware dot org
- Date: Sat, 19 Aug 2017 16:01:24 +0200
- Subject: _DIRENT_HAVE_D_RECLEN ignored by readdir
- Authentication-results: sourceware.org; auth=none
Hi, after enabling posix_dir=posix in for Jehanne OS, I've noticed
that readdir uses d_reclen even when _DIRENT_HAVE_D_RECLEN is not
defined.
Shouldn't it use sizeof(dirent) instead?
Moreover I had to redefine CC in my section of configure.host to add
the include dir inside the libc/sys/jehanne folder (where limits.h is
defined).
Something like what cygwin does:
> case "${host}" in
...
> *-*-jehanne*)
> test -z "$jehanne_srcdir" && jehanne_srcdir=`cd ${srcdir}/libc/sys/jehanne; pwd`
> export jehanne_srcdir
> CC="${CC} -I${jehanne_srcdir}/include"
> ;;
However I noticed that other ports (eg phoenix or rtems) do not need
such machinery. Is there a cleaner way to have
libc/sys/jehanne/include/ visible to the compiler for these files?
Thanks for your help!
Giacomo