Boaz Harrosh wrote:
Ken Larson wrote:
This assumes that I'm using winelib, correct? (I currently am not, I'm compiling on windows, but considering using winelib instead)
Yes!! Winelib can be both your DLL calling code, and you complete Linux application. No need for .EXE compiled or crosscompiled for windows, No need for IPC and no need for two parts at all. I apologize for the State of the documentation that this is not clear!
It as been proven that any windows code can be compiled as Winelib. If you are using core Libraries like MFC or ATL than that might get difficult (not impossible), but it seems this is not your case. On the other hand Winelib applications are a Linux applications so they can link to any Linux library. Just that they have a funny Makefile and are built with Winegcc.
Statically linking of a DLL is done as follows:
- Write a .spec file prototyping your DLL, than “winebuild” it to a .DEF
file. (make a rule for it in Makefile)
- Link your Winelib against that .DEF file like you do any other
Wine/Native DLL.
.spec file syntax is documented and should be simple. Now all this is easy if your DLL is extern "C". If it is C++ exports you'll need something extra. Is your DLL exporting C++ mangled symbols?
Free Life Boaz
Thanks for the info.
Ultimately, my app is a Java app. I am spawning my EXE wrapper around my DLL and talking to it from Java with sockets. So unless I'm missing something, my entire (Java) app can't be a winelib linux app (barring something like gcj which I'm not sure I'm ready for).
Ken