This is the mail archive of the newlib@sourceware.org mailing list for the newlib project.
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
| Other format: | [Raw text] | |
On Jul 6 13:08, Sebastian Huber wrote: > > > On 06/07/15 10:08, Corinna Vinschen wrote: > >Hi Marco, > > > >On Jul 5 16:33, Marco Atzeri wrote: > >>On 3/13/2015 1:24 PM, Corinna Vinschen wrote: > >>>Hi Sebastian, > >>> > >>>On Mar 13 11:00, Sebastian Huber wrote: > >>>>Merge parts of the latest <sys/time.h> from FreeBSD to Newlib. This has > >>>>two reasons. > >>>This patch also allowed to remove a Cygwin specific piece of code. > >>>I now pushed your patch as well as the Cygwin ones. > >>> > >>>Thanks, > >>>Corinna > >>> > >> > >>with the current settings, on cygwin with _GNU_SOURCE on > >>/usr/include/sys/time.h > >> > >>bintime_mul(struct bintime *_bt, u_int _x) > >>is included but > >> > >>u_int is not defined > >Thanks, but you forgot to paste this detail from your mail to the > >Cygwin list: > > > >>u_int is defined in > >> /usr/include/sys/types.h > >>and > >> /usr/include/sys/time.h > >>includes it, but it is coveread by a > >> > >> # ifndef _POSIX_SOURCE > >Also your project defines _POSIX_SOURCE. > > > >So while u_int is guarded !_POSIX_SOURCE, the bintime_mul inline function > >using it is guarded __BSD_VISIBLE. > > > >Sebastian, the easy way out would be to redefine bintime_mul to use > >and "unsigned int" as second parameter. > > > >OTOH, shouldn't the affected types in sys/types.h guarded __BSD_VISIBLE, > >too, instead? They are on FreeBSD, afaics. > > In FreeBSD sys/types.h we have: > > #if __BSD_VISIBLE > typedef unsigned char u_char; > typedef unsigned short u_short; > typedef unsigned int u_int; > typedef unsigned long u_long; > #ifndef _KERNEL > typedef unsigned short ushort; /* Sys V compatibility */ > typedef unsigned int uint; /* Sys V compatibility */ > #endif > #endif > > So this fits well with the bintime_mul(struct bintime *_bt, u_int _x). > [...] > So this uses the _POSIX_SOURCE define. I would adjust this to use the > __BSD_VISIBLE instead like on FreeBSD. Done. Thanks, Corinna -- Corinna Vinschen Cygwin Maintainer Red Hat
Attachment:
pgpSZXkCS4hb9.pgp
Description: PGP signature
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |