http://bugs.winehq.org/show_bug.cgi?id=58580
--- Comment #3 from Matteo Ceruti matteo.ceruti@gmail.com --- Thank you Alexandre for the explanation. I took a look at the unix call interface you were directing me too and I'm happy to report that although it took me some time I think I made it work. I successfully created a *.so file and a corresponding wrapper dll (built as 'builtin'). I was able to call into the dll from a client.exe and the wrapper dll then actually called into unix library once I had put dll and .so file into wine/lib/x86_64-unix and x86_64-windows respectively.
Here's my toy repo https://github.com/matatata/wine_unix_lib_example
So this Bug report can be closed I'd say.
Best regards.