Just another Perl shrine | |
PerlMonks |
Re: interface perl to C++ code with SWIG, re: void pointers?by syphilis (Archbishop) |
on Aug 27, 2017 at 00:56 UTC ( [id://1198093]=note: print w/replies, xml ) | Need Help?? |
After my initial gaff, I'll have another crack at providing something that might be marginally useful - and I second stevieb's request for more info.
Inline::CPP and (Inline::C) seem to be quite happy to directly access the library's version() function: Here's the Inline::CPP demo: That works just fine and outputs '42'. Of course, it's a little bit different in your case because version() is in a separate library, so your script would be something like: or, if you want to call the sub from perl as "version": I think SWIG should be capable of providing the same result. Cheers, Rob
In Section
Seekers of Perl Wisdom
|
|