public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libc/4495] New: _POSIX_V6_ILP32_OFFBIG shouldn't be defined for __WORDSIZE == 32
@ 2007-05-11 13:55 mfundarek at nds dot com
2007-05-23 10:23 ` [Bug libc/4495] " jakub at redhat dot com
0 siblings, 1 reply; 2+ messages in thread
From: mfundarek at nds dot com @ 2007-05-11 13:55 UTC (permalink / raw)
To: glibc-bugs
in bits/environments.h:
#if __WORDSIZE == 32
# define _POSIX_V6_ILP32_OFFBIG 1
# define _XBS5_ILP32_OFFBIG 1
#endif
then comment:
/* We optionally provide an environment with the above size but an 64-bit
side `off_t'. Therefore we don't define _XBS5_ILP32_OFFBIG. */
The Open Group Base Specifications Issue 6 IEEE Std 1003.1, 2004 Edition:
_POSIX_V6_ILP32_OFFBIG
The implementation provides a C-language compilation environment with 32-bit
int, long, and pointer types and an off_t type using at least 64 bits.
also from stdint.h chapter in POSIX specification:
If an implementation provides integer types with width 64 that meet these
requirements, then the following types are required: int64_t uint64_t
In particular, this will be the case if any of the following are true:
The implementation supports the _POSIX_V6_ILP32_OFFBIG programming
environment and the application is being built in the _POSIX_V6_ILP32_OFFBIG
programming environment (see the Shell and Utilities volume of IEEE Std
1003.1-2001, c99, Programming Environments).
...
My understanding:
If _POSIX_V6_ILP32_OFFBIG is defined then 64bit types are available, off_t will
be at least 64bits long. Same probably applies to _XBS5_ILP32_OFFBIG. All this
seems to be confirmed by the _XBS5_ILP32_OFFBIG comment quoted.
Suggestion:
Either undef both of these macros or
#if __WORDSIZE == 32
# define _POSIX_V6_ILP32_OFFBIG -1
# define _XBS5_ILP32_OFFBIG -1
#endif
--
Summary: _POSIX_V6_ILP32_OFFBIG shouldn't be defined for
__WORDSIZE == 32
Product: glibc
Version: unspecified
Status: NEW
Severity: normal
Priority: P2
Component: libc
AssignedTo: drepper at redhat dot com
ReportedBy: mfundarek at nds dot com
CC: glibc-bugs at sources dot redhat dot com
http://sourceware.org/bugzilla/show_bug.cgi?id=4495
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2007-05-23 10:23 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-05-11 13:55 [Bug libc/4495] New: _POSIX_V6_ILP32_OFFBIG shouldn't be defined for __WORDSIZE == 32 mfundarek at nds dot com
2007-05-23 10:23 ` [Bug libc/4495] " jakub at redhat dot com
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).