public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
From: Csaba Raduly <rcsaba@gmail.com>
To: Patrick L <patrick_lfa@yahoo.com>, cygwin@cygwin.com
Subject: Re: Why Cygwin tries to pull in winsock2.h when compiling a Linux application?
Date: Sat, 30 Jun 2012 09:43:00 -0000	[thread overview]
Message-ID: <CAEhDDbDARcKtJf=CxnbgkfSVB=r3PEmN2WmDwS5O7jS7ZA-h1A@mail.gmail.com> (raw)
In-Reply-To: <1341042078.16411.YahooMailNeo@web121706.mail.ne1.yahoo.com>

Hi Patrick

On Sat, Jun 30, 2012 at 9:41 AM, Patrick L  wrote:
> Hi, I am using Cygwin 1.7.11 i686 on Windows 7 PC. I am trying to compile a Linux C++ application on Cygwin.
>
> When I use the ./configure command, Cygwin shows the following error messages:
>
> checking winsock2.h usability... no
> checking winsock2.h presence... yes
> configure: WARNING: winsock2.h: present but cannot be compiled
(snip)
> winsock2.h and ws2tcpip.h are Windows header files for Windows network/socket programming. Why Cygwin tries to pull in Windows header files when I am compiling a Linux C++ application?

Because the configure script is trying to find them.
I suspect this is a program (or its configure script) which "thinks"
that Cygwin is Windows. (It appears to be testing explicitly for
winsock2.h; it shouldn't)

> How can I fix this issue?

Tell the authors of the program that Cygwin is not Windows.

Take a look at config.log; it should contain the error message from
the compiler when it tried to use winsock2.h
Search for         checking winsock2.h usability            in
config.log; there should be a short C source, a gcc invocation and an
error message.

Csaba
-- 
GCS a+ e++ d- C++ ULS$ L+$ !E- W++ P+++$ w++$ tv+ b++ DI D++ 5++
The Tao of math: The numbers you can count are not the real numbers.
Life is complex, with real and imaginary parts.
"Ok, it boots. Which means it must be bug-free and perfect. " -- Linus Torvalds
"People disagree with me. I just ignore them." -- Linus Torvalds

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

      parent reply	other threads:[~2012-06-30  9:43 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-30  7:41 Patrick L
2012-06-30  7:54 ` marco atzeri
2012-06-30  9:43 ` Csaba Raduly [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAEhDDbDARcKtJf=CxnbgkfSVB=r3PEmN2WmDwS5O7jS7ZA-h1A@mail.gmail.com' \
    --to=rcsaba@gmail.com \
    --cc=cygwin@cygwin.com \
    --cc=patrick_lfa@yahoo.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).