[Gambas-user] Working with .so library

Cedron Dawg cedron at exede.net
Wed Jun 26 17:54:41 CEST 2019


I've whipped up a sample project which should be similar to your situation.

This project shows:

 * How easy it is to interface to a C shared library.

 * My clever, but a bit complicated, way of compiling a C shared library from Gambas

 * The difference between Gambas' ordinary string functions (ASCII) and the static String functions (UTF-8)

You should note:

 * The C code is oblivious to the UTF-8 encoding of the string constant.

 * There is no conv function usage

 * I use a string instead of allocated memory

Hopefully this will clarify the issues at hand.

Ced

-------------- next part --------------
A non-text attachment was scrubbed...
Name: StringPassing-0.0.1.tar.gz
Type: application/x-compressed-tar
Size: 15240 bytes
Desc: not available
URL: <https://lists.gambas-basic.org/pipermail/user/attachments/20190626/b659d178/attachment.bin>


More information about the User mailing list