Hi Vladimir, > On 13 Jul 2016, at 22:40, Vladimir Marek <vladimir.ma...@oracle.com> wrote: > In order to play with perl I wanted to do a gui. I decided to try to > bind qt libraries via nativecall[1]. Nativecall contains logic for g++ > or msvc which tries to guess mangled name. I found that it does not work > that well for qt libraries. Especially on windows the actual symbols are > far from nativecall guess. So I decided I'll compile the shim library > exporting qt functionality into 'extern "C"' to make the symbols > predictable. Sadly I can't force nativecall to not mangle symbols at > all. I'm using the attached patch and in the perl itself > > class QString is repr<CPPStruct> is QObject { > has Pointer $.vtable; > > my sub qt_QString(Str) returns QString is native('./p6', v1) is > mangled(False) { * }; > ... > > Important is the 'is mangled(False)'. > > Could something like this be included into nativecall? > > [1] https://bitbucket.org/vlmarek/perl6-qt (beware, only proof of > concept) > > Thank you > -- > Vlad > <perl6.diff>
Could you please turn this into a PR on https://github.com/rakudo/rakudo ? That would make it easier for more people to look at and much easier to merge. Thanks! Liz