Wine as shared library patch

Robert Shearman R.J.Shearman at warwick.ac.uk
Thu Mar 4 15:53:05 CST 2004


Peter Dennis Bartok wrote:
> This patch allows to use Wine as a shared library. It will allow the
> Mono project to use Wine as the backend for it's System.Windows.Forms
> implementation.

It looks as though Alexandre has done a good job with kernel32 and ntdll
since the last time using Wine with Mono was mentioned on this list.

> ChangeLog:
>     * Alters initialization code to return control to caller instead of
> executing application if __wine_shared_lib flag is set.

Perhaps this could be changed to a static variable in process.c

>     * Adds winelib executable (wine-sharedlib) that a consumer can use
> to initialize Wine as a shared library, to load Wine DLLs and to import
> functions from DLLs.

wine-sharedlib doesn't look very clean at the moment. Tabs are inconsistent
and you forgot to change MonoWineInit to SharedWineInit in one of the
comments.
Why do you link to kernel32 and user32 and then use dlsym to get the
function address?
What is VideoDLL supposed to be for?
Why does the comment for WinMain say it is never called and then have a load
of junk in it?

If you can resolve these issues then we can have a single Wine for Win32 and
S.W.F!

Rob





More information about the wine-devel mailing list