Messages in this thread | ![/](/images/icornerl.gif) | | From | "Anthony Barbachan" <> | Subject | Re: linux headers and C++ | Date | Thu, 1 Jul 1999 17:36:51 -0400 |
| |
Trying surrounding the includes for the C based header files with
extern "C" { ... C header files ... }
----- Original Message ----- From: Ronnie G Misra <rgmisra@MIT.EDU> To: <linux-kernel@vger.rutgers.edu> Cc: <rgmisra@MIT.EDU> Sent: Thursday, July 01, 1999 5:16 PM Subject: linux headers and C++
> I'm trying to build a kernel module in C++. This code includes some of > the linux kernel header files, and unfortunately does not compile with > recent versions of the kernel. The code is not my own - I have > inherited it from someone else - but I am assured that it used to > compile. > > The error I get has to do with include/linux/signal.h under the kernel > source tree: the functions siginitset and siginitsetinv both contain > switch statements which are invalid C++ syntax (and in fact, are > invalid in C, but which make use of a gcc extension). Specifically, > the last label ("case 1:") in these statements should be followed by a > semicolon. > > I have just subscribed to the linux-kernel mailing list, but I am not > sure I will get your responses, so please cc any discussion of this to > my address. > > Thanks, > > Ronnie Misra rgmisra@mit.edu > 3 Ames Street, Box 152 > Cambridge, MA 02142 > (617) 225-6365 > > - > To unsubscribe from this list: send the line "unsubscribe linux-kernel" in > the body of a message to majordomo@vger.rutgers.edu > Please read the FAQ at http://www.tux.org/lkml/ >
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| ![\](/images/icornerr.gif) |