compiling windows C++ code base using winelib

Open forum for end-user questions about Wine. Before asking questions, check out the Wiki as a first step.
Forum Rules
Locked
yugandhar
Level 2
Level 2
Posts: 25
Joined: Mon Dec 01, 2008 11:08 am

compiling windows C++ code base using winelib

Post by yugandhar »

Hi,

My application holds few windows exe's developed using .lib libraries. This application which got developed using VC++ is working fine when executed using wine.I want to compile the same source using winelibraries in linux. How can I include c++ header files? I can see only windows and msvcrt header files under wine?
Any help would be appreciated on this C++ header stuff for wine.

Thanks,
Yug
vitamin
Moderator
Moderator
Posts: 6605
Joined: Sat Feb 23, 2008 2:29 pm

Re: compiling windows C++ code base using winelib

Post by vitamin »

yugandhar wrote:How can I include c++ header files?
If you talking about MFC - then you out of luck. Wine doesn't have those.
Evil Jay

compiling windows C++ code base using winelib

Post by Evil Jay »

Someone should suggest to MS that if they're serious about open source
that they should open-source the MFC libraries. After all, a lot of us
did waste a huge amount of time becoming proficient with it to see it
replaced by ATL then .Net.

-J


vitamin wrote:
yugandhar wrote:
How can I include c++ header files?
If you talking about MFC - then you out of luck. Wine doesn't have those.
Thunderbird
Level 5
Level 5
Posts: 336
Joined: Mon Nov 24, 2008 8:10 am

Post by Thunderbird »

Why do you want to recompile your app using winelib? The gain of recompiling using winelib is very small. In general you only want to do that when you want to run your app on a non-x86 architecture. For performance it doesn't really matter if it is a win32 executable or not. Most apps that use wine e.g. Google's Picasa and others are just win32 binaries.

You can also just use winelib to port small pieces of your app if you want to make some native linux calls. To do this just put some functionality in a dll and port that dll using wlnelib (in winelib you can mix both win32 and linux code). Because Wine sees no difference between a win32 mylib.dll or a winelib mylib.dll.so that way works fine. This way is recommended as it is a HUGE task to port a full app using wineg++t.
yugandhar
Level 2
Level 2
Posts: 25
Joined: Mon Dec 01, 2008 11:08 am

Post by yugandhar »

Thanks for your quick replies.

Basically my application runs on depending 8 executables.If I run all these executables using wine which inturn depends on Wineserver which may be a bottleneck.I mean to say if the winesever gets crashed then my application will come down.Instead of this I planned to build all the executables using winelib.It doesnt use any MFC classes whereas includes wine32 APIs with C++ code base.


Thanks,
Yug
austin987
Wine Developer
Wine Developer
Posts: 2383
Joined: Fri Feb 22, 2008 8:19 pm

compiling windows C++ code base using winelib

Post by austin987 »

On Sat, Jan 24, 2009 at 7:48 PM, yugandhar <[email protected]> wrote:
Thanks for your quick replies.

Basically my application runs on depending 8 executables.If I run all these executables using wine which inturn depends on Wineserver which may be a bottleneck.I mean to say if the winesever gets crashed then my application will come down.Instead of this I planned to build all the executables using winelib.It doesnt use any MFC classes whereas includes wine32 APIs with C++ code base.


Thanks,
Yug





If you compile with winelib, it will still use wineserver.

--
-Austin
yugandhar
Level 2
Level 2
Posts: 25
Joined: Mon Dec 01, 2008 11:08 am

Post by yugandhar »

Austin,

Is there any option using winelib I can build linux executables using windows source code independent of wineserver.

-Yug
austin987
Wine Developer
Wine Developer
Posts: 2383
Joined: Fri Feb 22, 2008 8:19 pm

compiling windows C++ code base using winelib

Post by austin987 »

On Mon, Jan 26, 2009 at 9:08 AM, yugandhar <[email protected]> wrote:
Austin,

Is there any option using winelib I can build linux executables using windows source code independent of wineserver.

-Yug
Not that I'm aware of, but I could be wrong. Also, it's pedantic, but
wine != windows source code.

--
-Austin
vitamin
Moderator
Moderator
Posts: 6605
Joined: Sat Feb 23, 2008 2:29 pm

Post by vitamin »

yugandhar wrote:Is there any option using winelib I can build linux executables using windows source code independent of wineserver.
No. If your program uses registry, creates a window, opens file or does anything useful you have to have wineserver. It's the Wine's "kernel".
Locked