> I don't really know how the Ada compiler works, but it looks like this > code is generated by the gnatbind program. I bet it would work if > gnatbind -C emitted this at the start of the output: > > #ifdef __cplusplus > extern "C" { > #endif > > and emitted this at the end: > > #ifdef __cplusplus > } > #endif > > I think the function to change is Gen_Output_File_C in bindgen.adb.
Looks like a good track indeed and a reasonable change to make IMO. Arno