delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2012/03/16/16:42:18

X-Recipient: archive-cygwin AT delorie DOT com
X-SWARE-Spam-Status: No, hits=-1.8 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE
X-Spam-Check-By: sourceware.org
X-Mail-Handler: MailHop Outbound by DynDNS
X-Report-Abuse-To: abuse AT dyndns DOT com (see http://www.dyndns.com/services/mailhop/outbound_abuse.html for abuse reporting information)
X-MHO-User: U2FsdGVkX19E8VJ0xUs6nxKX4zKO7hMY
Date: Fri, 16 Mar 2012 16:41:55 -0400
From: Christopher Faylor <cgf-use-the-mailinglist-please AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: sys/filio.h
Message-ID: <20120316204155.GE20353@ednor.casa.cgf.cx>
Reply-To: cygwin AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
References: <BAY156-W21C7B0B6880EB72A802F29C95F0 AT phx DOT gbl>
MIME-Version: 1.0
In-Reply-To: <BAY156-W21C7B0B6880EB72A802F29C95F0@phx.gbl>
User-Agent: Mutt/1.5.20 (2009-06-14)
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

[formatting fixed]
On Fri, Mar 16, 2012 at 04:23:32PM -0400, Tom Szczesny wrote:
>There are several places in the source code that have the following
>type of construction:
>
>#if defined(_AIX) || defined(linux) || defined(__alpha) || defined(__APPLE__)
>extern "C" {
>#include <sys/ioctl.h>
>}
>#else
>extern "C" {
>#include <sys/filio.h>}
>#endif
>
>As a temporary measure, I have added a line at the beginning of each
>construction, stating:
>
>#define linux
>
>While this works as a temporary fix, I need to know the name of the
>variable automatically defined by Cygwin so that I can do something
>like:
>
>#if defined(_AIX) || defined(linux) || defined(__alpha) || defined(__APPLE__) || defined(cygwin)
>
>There is quite a long build going at the momemt, and I don't want to
>interrupt it to test out different possibilities.Can you either confirm
>that the defined variable is named "cygwin", or tell me what the actual
>name is?

You don't have to interrupt a build to play with the c compiler or
grep /usr/include.

As a fish teaching exercise, try this command:

gcc -xc /dev/null -dD -E

cgf

--
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

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019