[lkml]   [2005]   [Sep]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: kbuild & C++
On Wed, 2005-09-07 at 11:21 +0200, Esben Nielsen wrote:
> On Tue, 6 Sep 2005 wrote:
> > On Wed, 07 Sep 2005 00:20:11 +0200, Esben Nielsen said:
> >
> > > Which is too bad. You can do stuff much more elegant, effectively and
> > > safer in C++ than in C. Yes, you can do inheritance in C, but it leaves
> > > it up to the user to make sure the type-casts are done OK every time. You
> > > can with macros do some dynamic typing, but not nearly as effectively as
> > > with templates, and those macros always comes very, very ugly. (Some say
> > > templates are ugly, but they first become ugly when they are used
> > > way beyond what you can do with macros.)
> > >
> > > I think it can only be a plus to Linux to add C++ support for at least
> > > out-of-mainline drivers. Adding drivers written in C++ into the mainline
> > > is another thing.
> >
> > Why don't we rewrite the Linux kernel in C++?
> I can't see it should be _that_ hard to make the kernel C++ friendly. At work
> I use a RTOS written in plain C but where you can easily use C++ in kernel
> space (there is no user-space :-). We use gcc by the way.

Of course. Probably the easiest way is
-) to provide a pure C interface (read: write functions with C linkage
that call your C++ stuff) to your C++ stuff
-) compile your C++ sources separately
-) kill all not-existing features needed by the linker and other
programs (or implement them in the kernel/your module).

> PS. Do the above people break GPL by forcing people to accept a
> license-agreement before downloading a patch to the kernel? Shouldn't they
> provide a direct url?

As long as the license agreement does not conflict with the GPL, I can't
see a legal problem. And you can download their source - which is
probably GPL - and put it online wherever you want.
It is inpolite though, IMHO. But it is also inpolite to top-post, break
threads, include meaningless disclaimers, etc.

Firmix Software GmbH
mobil: +43 664 4416156 fax: +43 1 7890849-55
Embedded Linux Development and Services

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2005-09-07 13:47    [W:0.048 / U:3.964 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site