[Mono-list] C#->C->C++, Platform Invocations from HELL!
R. Tyler Ballance
tyler at bleepconsulting.com
Mon Dec 11 05:20:22 EST 2006
Alright, alright, so the subject is a bit extreme (XTREME!!)
Anyways, I'm working on some projects that have led me down the dark,
lonely path to p/invoke as some of you from the #mono IRC channel may
know, but I'm somewhat proud of reaching this new level of oddity :)
Rumour has it I've been saddled with a C++ library that I need to in
some way shape or form incorporate into our new heavily-reliant Mono/
C# based project. Platform invocations aren't anything new to me at
this point, enough so that I know that Managed C++ is a MS.NET
bastard child, and that such sorcery the Mono runtime does not contain.
I'm wondering if it is a plausible option to wrap the C++ shared
libraries with a C library, which would then be wrapped by the C#
platform invocation wrappers that I'd write, much in the same manner
Mac OS X APIs perform toll-free bridging between ObjC and C (http://
ridiculousfish.com/blog/archives/2006/09/09/bridge/)
The most I have to worry about really in the context of C++ specific
code is sick iterator hacks and exceptions, but I don't think it
isn't anything that can't be wrapped by a simpleton C wrapper to
provide a good p/invoke shim for Mono.
Am I stretching too far?
Cheers
R. Tyler Ballance: Custom Mac and Linux Development at bleep. consulting
contact: tyler at bleepconsulting.com | jabber: tyler at jabber.geekisp.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/mono-list/attachments/20061211/aa072359/attachment-0001.html
More information about the Mono-list
mailing list