In my winelib app, most of the cpp files use MSVCRT only, and thanks to Martin I've gotten those to compile.
A couple of my source files, however, use a mix of MSVCRT and standard glibc (fork, exec, etc). When I include unistd.h, lots of function definitions conflict with msvcrt/io.h. How can I get this mix to compile? Does the @ignore in the spec file trick from the Winelib user's guide still apply, or has it been changed (or removed altogether)?
-Steve
Am Die, 2002-09-17 um 21.47 schrieb steve.lustbader@philips.com:
In my winelib app, most of the cpp files use MSVCRT only, and thanks to Martin I've gotten those to compile.
If the small patches I sent make your app _run_ fine, too, please notify me - I'll submit official. patches to Alexandre in that case.
A couple of my source files, however, use a mix of MSVCRT and standard glibc (fork, exec, etc). When I include unistd.h, lots of function definitions conflict with msvcrt/io.h.
It is new to me that fork() and exec() are supported on windows - what kind of app are you porting?
How can I get this mix to compile? Does the @ignore in the spec file trick from the Winelib user's guide still apply, or has it been changed (or removed altogether)?
Here's what I would try: Encapsulate the Unix-specific calls in a separate source file(s) that compiles against the system headers, wrap the Unix calls in functions exported by these files, and then "simply" link the winelibwise and unixwise parts of your application.
Dividing the the two worlds over source files should have other benefits as well, softwaredesignwise :-)
Martin