C++ bindings

Havoc Pennington hp@redhat.com
Thu, 06 Nov 2003 14:29:51 -0500

On Thu, 2003-11-06 at 14:19, Murray Cumming wrote:
> I'm playing around at doing some DBUS C++ bindings.
> Do you really want to ship bindings with DBUS itself?

It's up to you. Since people would be downloading gtkmm stuff already,
maybe shipping it with that makes more sense (I don't mean same tarball,
just same ftp site, etc.)

> If you do, then
> I'll probably need to put them under the dbus directory, e.g.
>   dbus/dbus/C sources
>   dbus/dbus/cpp/C++ bindings
> or put dbus in the name, unlike the other bindings. e.g.
>   dbus/dbus/C sources
>   dbus/dbus-cpp/C++ bindings.
> This will allow my headers to use a full path in #includes. Do you have
> a preference?

Could you do cxx/dbus/dbus.h perhaps?

cpp means "C preprocessor" to me but maybe not to others.

I would suggest you probably want to do some code generation, and you
could use the same code generator as dbus-glib. (Though this generator
is not really written, it's half-started-on.)

By code generation I mean either IDL -> sourcecode (CORBA model), or 
sourcecode -> IDL -> typelib (moc/DCOP model). Or IDL -> typelib
perhaps, if you want to make people do more typing.