[sane-devel] Can I use c++ in sane-backend programing?

René Rebe rene at exactcode.de
Mon Oct 10 08:19:36 UTC 2005


Hi,

On Monday 10 October 2005 17:17, kenwhale wrote:

> Hi, all.
>      I read backend-writing.txt in www.sane-project.org. It says:
> * Use only ANSI C for your backend. C99 is not supported by the
> compilers of some older platforms so please avoid using its features.
>      Does that mean I must write my backend in c and can't use c++ ?

In theory you can write in any language with a C binding. However on many of 
the esoteric platforms we support this does not work.

So you could write it in C++ and make a configure check for your language (C++ 
here) and conditionally compile it when it is available. However you restrict 
your backend to platforms where a recent enough (depending what C++ features 
you use) is availbale.

Distributing seperateded from sane-backends is another options.

Yours,

-- 
René Rebe - Rubensstr. 64 - 12157 Berlin (Europe / Germany)
            http://www.exactcode.de | http://www.t2-project.org
            +49 (0)30  255 897 45
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.alioth.debian.org/pipermail/sane-devel/attachments/20051010/0b5652e2/attachment.pgp


More information about the sane-devel mailing list