sancts
2009-May-24 13:38 UTC
[Wine] directions for porting my own code using 3rd party dll
Hi I have a c++ project Im working on under windows. it uses a 3rd party library (ie, i have headers and dll). mostly for development I'd like to be able to work on it under linux. and i thought that should be easy with wine. but now i read through the Winelib User's Guide and Im somewhat lost. its talking about winemaker and bad cases of filenames, generating makefiles and stuff. Im pretty sure thats not an issue in my situation. I can compile my code using g++ and the 3rd party headers(almost - theres something related to some macros inside these headers ... but i think i should be able to resolve that) but i cant link it (obviously - its .dll ) can someone give me some hint about how to proceed, what to read? thx
Thunderbird
2009-May-24 13:54 UTC
[Wine] Re: directions for porting my own code using 3rd party dll
It is not possible to simply use winelib for linking to a win32 dll. You have to compile ALL of your code using winegcc/wineg++, so your whole app will depend on wine. The reason for this is that wine needs to do a lot of magic (registry, file system, windows memory layout ...). If you don't want that then the only way is to write a small winelib app and use some form of IPC to communicate between the linux and winelib app (e.g. using unix sockets or whatever). Look at the wine-devel archive for discussions about this.