linux executable loading linux .so which calls windows dll

Open forum for end-user questions about Wine. Before asking questions, check out the Wiki as a first step.
Forum Rules
Locked
malbec
Newbie
Newbie
Posts: 2
Joined: Wed Aug 31, 2011 10:38 am

linux executable loading linux .so which calls windows dll

Post by malbec »

I want to write a linux .so that calls a windows .dll, which will be loaded (all by itself) as an extension to a linux executable. any tips on where to start? would it be better to start under linux using gcc + wine tools or under windows using mingw ...-> cross-compilation? not sure where to start. not sure if its possible. please advise.
vitamin
Moderator
Moderator
Posts: 6605
Joined: Sat Feb 23, 2008 2:29 pm

Re: linux executable loading linux .so which calls windows d

Post by vitamin »

malbec wrote:I want to write a linux .so that calls a windows .dll, which will be loaded (all by itself) as an extension to a linux executable.
Short answer - in 99% cases this won't work.

Long answer - to load a Windows DLL you need big parts of Wine. Unless you willing to spend weeks stripping all extras, it's better to use the entire Wine. And compile your "linus .so" as a winelib.
User avatar
André H.
Moderator
Moderator
Posts: 207
Joined: Sun Dec 07, 2008 8:33 am

Post by André H. »

the winemaker tool is your friend.
(and the outdated guide: http://www.winehq.org/docs/winelib-guide/index)
Locked