This is the mail archive of the cygwin-xfree@sources.redhat.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Development Status Update 2


On Tue, Nov 21, 2000 at 11:25:10PM -0500, Harold Hunt wrote:
>Today I figured out a workable solution for making the X headers play nice
>with the Windows headers; the solution involves using the Wine headers for
>Windows (as they allow more precise control over which headers are included)
>and the user headers for X (think Xlib.h instead of pixmap.h). I'm satisfied
>with this solution, at this point, as it allows us to move on with
>programming instead of rewriting or adding #ifdef's to lots of header files.
>We might want to revisit the header issue when we get more of a product in
>place.

I can't say that I like the solution of using a completely different set
of headers.  That sounds like a customer support issue waiting to happen.
Anyone who wants to build stuff will have to go to multiple different sources
to retrieve what they need.

Most of the Windows stuff in cygwin is broken up into separate files.  You
don't have to include the monolithic "windows.h" file to get everything that
you need.  The layout is, in fact, similar to Microsoft's.

Maybe you've investigated this already but I thought I'd throw this out in
case you hadn't.

The other alternative is to create wrappers for windows header files which
'#define' problematic variables and functions to something less problematic
and them undef them after the header is included.

It should be relatively simple to find the functions and variables that are
causing problems if you attempt to compile a few source files and then collect
the names of all of the variables into a text file where you can do some bulk
editing to create the '#define Foo OccludeWindowsFoo/#undef Foo' pairs.

Maybe this has already been suggested.  I haven't been paying close attention.
Apologies, if so.

It just seems to me that pulling in header files from another project is not
a terrific solution.

cgf

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]