Okay so I have a bunch of
.dll files that are compiled on windows (though I could recompile them on linux if that was necessary) that I want to use.
The final idea I am having is to write a
.so that will be able to call the functions defined in the
As far as I have read this should be possible by using
mono but I just can't seem to find any resource on how that might actually work. And by that I mean a specific example demonstrating the basics.
So let's assume I have a
.dll that contains a function called
getText() that will return the String
"Hello World" when called.
How can I write my C++ code (I want it to be compiled to a
.so so that's what I have to use, right?) that it calls that function and prints the returned String to the console? Is this even possible?
If the above scenario isn't possible: How can I use mono in general to access
dlls? I have already written a C# example that does the job but ultimately I need a
.so so this is not an option. Might there be some way to use mono from the command line to execute the function?
Another thing I found is the loadlibrary framework which seems to be capable of what I am looking for. However I have no clue how I would use it, so I'd appreciate a little code-example