windows app to communicate with cocoa lib

Open forum for end-user questions about Wine. Before asking questions, check out the Wiki as a first step.
Forum Rules
Locked
jwong
Level 2
Level 2
Posts: 25
Joined: Thu Feb 17, 2011 4:58 pm
Location: US

windows app to communicate with cocoa lib

Post by jwong » Mon Feb 28, 2011 5:05 pm

Does anyone know of a way to get my Windows MFC app running under WINE to call a function in a native OS X lib or plugin? I would like the ability for my Windows app to call some custom functions which would pull information about the current machine, such as OS X version for example.

I dont really care as to how but I was thinking I could write a 'generic c++ plugin' or 'c++ dynamic library' in cocoa and then wrap that into a Windows dll. Or I could write a lib, compile it with winelib lib and call it. But is either scenario even possible? And how?

If you could point me in right direction for documentation that would be helpful too.

Thanks

Thunderbird
Level 5
Level 5
Posts: 336
Joined: Mon Nov 24, 2008 8:10 am

Post by Thunderbird » Mon Feb 28, 2011 6:37 pm

That's the whole purpose of Winelib. In code compiled using Winelib you can make both Win32 and 'native' OS calls. Any function exported through a so called '.spec' file can be used directly by a Windows application. Look for more information in docs.

Locked