This is the mail archive of the
newlib@sources.redhat.com
mailing list for the newlib project.
Re: several more bugs found by coreutils
- From: Eric Blake <ebb9 at byu dot net>
- To: cygwin at cygwin dot com, newlib at sources dot redhat dot com
- Date: Wed, 02 Feb 2005 07:05:13 -0700
- Subject: Re: several more bugs found by coreutils
- References: <020120052058.2301.41FFED5A000D5EEC000008FD22007614380A050E040D0C079D0A@comcast.net> <20050202100718.GA7767@cygbert.vinschen.de>
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
According to Corinna Vinschen on 2/2/2005 3:07 AM:
> This is newlib schtuff, so I CCd the newlib mailing list.
> [Resend because I forgot the CC]
>
> On Feb 1 20:58, Erik Blake wrote:
Eric, not Erik.
>
> include/pwd.h is a newlib file. However, I was pretty happy that pw_uid
> and pw_gid were defined as int, when we changed uids and gids from 16 to
> 32 bits. It was the one file which wasn't necessary to change.
Is it worth introducing two definitions in cygwin, guarded by
__CYGWIN_USE_BIG_TYPES__, as is done elsewhere (for example sys/dirent.h)?
Or how about something like the following to ensure that pw_comment
remains at the same offset regardless of whether sizeof(uid_t) == sizeof(int):
struct passwd {
char *pw_name;
char *pw_passwd;
union {
int __filler;
uid_t upw_uid;
} u;
/* etc. */
};
#define pw_uid u.upw_uid;
>
> We could just redefine struct passwd to use uid_t and gid_t, but this
> would break (very very very very unlikely) builds of Cygwin using
> sources of versions before 1.5.0. In other words, old Cygwin sources
> using 16 bit uids/gids would go down hell.
>
> Personally, I think I can live with that, but I would like to hear if
> there's any good reason to build historic versions (say, b20) with a
> recent newlib.
I don't think so. Anyone brave enough to want to build something that old
should build a complete system from sources from that time, rather than
mixing and matching old cygwin with newer newlib.
- --
Life is short - so eat dessert first!
Eric Blake ebb9@byu.net
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
iD8DBQFCAN4Y84KuGfSFAYARAt1lAJ46vOz6gvcl7SiBkxwKBd8iEcBNbQCgtZ2Q
2XbV6wiOwFOVFhNFF4TcObg=
=nBdH
-----END PGP SIGNATURE-----