public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
* [Bug other/36368] New: Fixincludes corrupts sysmacros.h @ 2008-05-29 11:56 joerg dot richter at pdv-fs dot de 2008-05-29 12:04 ` [Bug other/36368] " rguenth at gcc dot gnu dot org ` (2 more replies) 0 siblings, 3 replies; 4+ messages in thread From: joerg dot richter at pdv-fs dot de @ 2008-05-29 11:56 UTC (permalink / raw) To: gcc-bugs Compiling this program: #include <sys/types.h> $ gcc a.c In file included from /usr/include/sys/types.h:219, from a.c:1: /pdv/.tools/pkg/gcc/4.3.0/bin/../lib/gcc/i686-pc-linux-gnu/4.3.0/include-fixed/sys/sysmacros.h:52: error: expected ',' or ';' before '{' token /pdv/.tools/pkg/gcc/4.3.0/bin/../lib/gcc/i686-pc-linux-gnu/4.3.0/include-fixed/sys/sysmacros.h:58: error: expected ',' or ';' before '{' token /pdv/.tools/pkg/gcc/4.3.0/bin/../lib/gcc/i686-pc-linux-gnu/4.3.0/include-fixed/sys/sysmacros.h:64: error: expected ',' or ';' before '{' token $ gcc -v Using built-in specs. Target: i686-pc-linux-gnu Configured with: /ws/jrichter/nfs/src/bld/cfg/build/tmp.evo4.19802/gcc-4.3.0/configure --prefix=/tools/pkg/gcc/4.3.0 --enable-languages=c,c++ --disable-threads --with-gmp=/tools/pkg/gmp/4.2.2 --with-mpfr=/tools/pkg/mpfr/2.3.1 Thread model: single gcc version 4.3.0 (GCC) $ uname -a Linux evo4 2.4.21-47.0.1.ELsmp #1 SMP Fri Oct 13 17:56:20 EDT 2006 i686 i686 i386 GNU/Linux Here is the relevant part of diff -u /usr/include/sys/sysmacros.h .../include-fixed/sys/sysmacros.h # if defined __GNUC__ && __GNUC__ >= 2 -__extension__ extern __inline unsigned int -__NTH (gnu_dev_major (unsigned long long int __dev)) +__extension__ extern __inline __attribute__ ((__gnu_inline__)) unsigned int +gnu_dev_major (unsigned long long int __dev) __THROW { return ((__dev >> 8) & 0xfff) | ((unsigned int) (__dev >> 32) & ~0xfff); } Note that __THROW expands to __attribute__ ((__nothrow__)) when compiling in C. But it seems this attribute isn't allowed on function definitions. -- Summary: Fixincludes corrupts sysmacros.h Product: gcc Version: 4.3.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: other AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: joerg dot richter at pdv-fs dot de http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36368 ^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug other/36368] Fixincludes corrupts sysmacros.h 2008-05-29 11:56 [Bug other/36368] New: Fixincludes corrupts sysmacros.h joerg dot richter at pdv-fs dot de @ 2008-05-29 12:04 ` rguenth at gcc dot gnu dot org 2008-05-29 12:22 ` joerg dot richter at pdv-fs dot de 2009-06-15 20:48 ` geir at cray dot com 2 siblings, 0 replies; 4+ messages in thread From: rguenth at gcc dot gnu dot org @ 2008-05-29 12:04 UTC (permalink / raw) To: gcc-bugs ------- Comment #1 from rguenth at gcc dot gnu dot org 2008-05-29 12:04 ------- Please specify the glibc version you are using and attach both the unfixed and the fixed header. -- rguenth at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Fixincludes corrupts |Fixincludes corrupts |sysmacros.h |sysmacros.h http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36368 ^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug other/36368] Fixincludes corrupts sysmacros.h 2008-05-29 11:56 [Bug other/36368] New: Fixincludes corrupts sysmacros.h joerg dot richter at pdv-fs dot de 2008-05-29 12:04 ` [Bug other/36368] " rguenth at gcc dot gnu dot org @ 2008-05-29 12:22 ` joerg dot richter at pdv-fs dot de 2009-06-15 20:48 ` geir at cray dot com 2 siblings, 0 replies; 4+ messages in thread From: joerg dot richter at pdv-fs dot de @ 2008-05-29 12:22 UTC (permalink / raw) To: gcc-bugs ------- Comment #2 from joerg dot richter at pdv-fs dot de 2008-05-29 12:21 ------- Seems I've used gcc on a machine with a newer libc than it was built on. Sorry for the noise. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36368 ^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug other/36368] Fixincludes corrupts sysmacros.h 2008-05-29 11:56 [Bug other/36368] New: Fixincludes corrupts sysmacros.h joerg dot richter at pdv-fs dot de 2008-05-29 12:04 ` [Bug other/36368] " rguenth at gcc dot gnu dot org 2008-05-29 12:22 ` joerg dot richter at pdv-fs dot de @ 2009-06-15 20:48 ` geir at cray dot com 2 siblings, 0 replies; 4+ messages in thread From: geir at cray dot com @ 2009-06-15 20:48 UTC (permalink / raw) To: gcc-bugs ------- Comment #3 from geir at cray dot com 2009-06-15 20:47 ------- For another point of reference, I see this problem in our GCC 4.3.1 build; but the problem did not occur in our gcc 4.3.0 and 4.3.2 versions. I assume this was an error on our part. $ diff /opt/gcc/4.3.1/snos/lib/gcc/x86_64-suse-linux/4.3.1/include-fixed/sys/sysmacros.h /opt/gcc/4.3.0/snos/lib/gcc/x86_64-suse-linux/4.3.0/include-fixed/sys/sysmacros.h 11c11 < Copyright (C) 1996, 1997, 1999, 2003 Free Software Foundation, Inc. --- > Copyright (C) 1996, 1997, 1999, 2003, 2004 Free Software Foundation, Inc. 51c51 < gnu_dev_major (unsigned long long int __dev) __THROW --- > __NTH (gnu_dev_major (unsigned long long int __dev)) 57c57 < gnu_dev_minor (unsigned long long int __dev) __THROW --- > __NTH (gnu_dev_minor (unsigned long long int __dev)) 63c63 < gnu_dev_makedev (unsigned int __major, unsigned int __minor) __THROW --- > __NTH (gnu_dev_makedev (unsigned int __major, unsigned int __minor)) $ diff /opt/gcc/4.3.1/snos/lib/gcc/x86_64-suse-linux/4.3.1/include-fixed/sys/sysmacros.h /opt/gcc/4.3.2/snos/lib/gcc/x86_64-suse-linux/4.3.2/include-fixed/sys/sysmacros.h 11c11 < Copyright (C) 1996, 1997, 1999, 2003 Free Software Foundation, Inc. --- > Copyright (C) 1996, 1997, 1999, 2003, 2004 Free Software Foundation, Inc. 51c51 < gnu_dev_major (unsigned long long int __dev) __THROW --- > __NTH (gnu_dev_major (unsigned long long int __dev)) 57c57 < gnu_dev_minor (unsigned long long int __dev) __THROW --- > __NTH (gnu_dev_minor (unsigned long long int __dev)) 63c63 < gnu_dev_makedev (unsigned int __major, unsigned int __minor) __THROW --- > __NTH (gnu_dev_makedev (unsigned int __major, unsigned int __minor)) $ diff /opt/gcc/4.3.0/snos/lib/gcc/x86_64-suse-linux/4.3.0/include-fixed/sys/sysmacros.h /opt/gcc/4.3.2/snos/lib/gcc/x86_64-suse-linux/4.3.2/include-fixed/sys/sysmacros.h $ -- geir at cray dot com changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |geir at cray dot com http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36368 ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2009-06-15 20:48 UTC | newest] Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2008-05-29 11:56 [Bug other/36368] New: Fixincludes corrupts sysmacros.h joerg dot richter at pdv-fs dot de 2008-05-29 12:04 ` [Bug other/36368] " rguenth at gcc dot gnu dot org 2008-05-29 12:22 ` joerg dot richter at pdv-fs dot de 2009-06-15 20:48 ` geir at cray 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).