This is the mail archive of the cygwin@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: Can't build Make from source because Windows header filesmoved to /usr/include/w32api?


Jonathan Kamens wrote:
> 
> >  Date: Wed, 28 Feb 2001 18:30:25 -0500
> >  From: Earnie Boyd <earnie_boyd@yahoo.com>
> >
> >  > I know how to work around this, but my question is.... Is this a known
> >  > problem, what's the correct way to fix it, and when will it be fixed
> >  > in the precompiled stuff being distributed by RedHat?
> >  >
> >
> >  CC='gcc -mwin32' ../configure
> 
> Thanks, but I don't think this really answers my question.
> 

Did you even stop to think that I might know exactly what I'm saying and
try it?!?!?!?!?!?!?!?

> Shouldn't "configure" for a Cygwin source package just Do The Right
> Thing?  

Configure doesn't know that you want to use /usr/include/w32api.  Adding
CC='gcc -mwin32' will cause the appropriate macros and switches to be
applied to the compiler.  You state in before configure so that
configure can build your Makefile with the CC variable set correctly.

> That's the whole point of "configure", isn't it?  

Configure has to make assumptions, sometimes those assumptions don't fit
so you have to control it.

> So if some
> Cygwin source packages depend on win32 header files or whatever,
> shouldn't the configure script included with those packages
> automatically add "-mwin32" or "-I/usr/include/w32api" or whatever to
> the compiler flags?
> 

You obviously don't understand configure or autoconf.  Also, this is a
recent change and some package configurations will have to go through a
few changes if the w32api headers are to be used.  What "Cygwin package"
are you referring to?  Cygwin is trying it's best to emulate UNIX/POSIX
and should by default not know about Win32 functions so this should be
an uncommon issue.  However Cygwin has been around long enough for
coding such as
  #if defined(_WIN32) || defined(__CYGWIN__)
  #include <windows.h>
  #endif
to exist.  If you wish to use the w32api with GCC-2.95.2-7 then you must
  CC='gcc -mwin32' ../configure
without exception.

Earnie.

Earnie.

_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com


--
Want to unsubscribe from this list?
Check out: http://cygwin.com/ml/#unsubscribe-simple


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