Hi Max,
your video is good, too bad that it stops prematurely.
It helped me to spot a tiny issue with the libgit2 generation script. The C compile options ( '-D__STDC_CONSTANT_MACROS' �'-D__STDC_LIMIT_MACROS') that are present there are just a copy paste error, since when created that method I've modified the one I've used for generating llvm bindings (which really needs them).
For libgit2 i don't now, I think they aren't needed. I've just tried on my machine with �options := {('-I' , includeDir fullName)}.
and it seems to work
Now libclang is the reason that in some cases we need such options. Since we use libclang to parse the header files we should make sure that we pass it everything it needs to successfully process the header.�
So if anyone has a hard time generating bindings with talkffi for a library X, then a starting point might be to try understanding what are the options needed by clang to compile the headers.
In the future I plan to add some kind of script editor for writing the bindings, which will show the messages from libclang. so that in case of compilation error (due to missing options, or c syntax errors) we can see them in the image.
About generating the bindings directly on a mac, I've done it using a hand compiled version of libclang configured with (../configure --enable-optimized --enable-jit --target=i686-apple-darwin10). So if you are willing to download libclang and compile it, maybe you don't need a linux vm.
Ok, that's it for now. Thanks again for the great video
Ciprian
�