This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
other/9244: NetBSD sys/cdefs.h needs a fixincludes hack
- From: rearnsha at arm dot com
- To: gcc-gnats at gcc dot gnu dot org
- Cc: thorpej at netbsd dot org
- Date: 9 Jan 2003 14:06:15 -0000
- Subject: other/9244: NetBSD sys/cdefs.h needs a fixincludes hack
- Reply-to: rearnsha at arm dot com
>Number: 9244
>Category: other
>Synopsis: NetBSD sys/cdefs.h needs a fixincludes hack
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: unassigned
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Thu Jan 09 06:16:03 PST 2003
>Closed-Date:
>Last-Modified:
>Originator: Richard Earnshaw
>Release: unknown-1.0
>Organization:
>Environment:
any NetBSD target for any relase other than -current. Any release of GCC with the new C++ parser.
>Description:
The new C++ parser rejects the (invalid) construct
extern "C" {
// decls
}; // Bogus semicolon
But this is the way that __END_DECLS in sys/cdefs.h is defined on existing NetBSD installations. (Current has now been fixed.)
>How-To-Repeat:
Try to build any C++ program that includes stdio.h with the new compiler on NetBSD
>Fix:
Add a fixincludes rule to fix this case up. The file is sys/cdefs.h and the macro __END_DECLS is defined to '};' rather than just '}'
Note that the definition of __END_DECLS as an empty define must not be affected; this is needed for C.
>Release-Note:
>Audit-Trail:
>Unformatted: