delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2001/03/10/17:10:14

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sources DOT redhat DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sources DOT redhat DOT com>
List-Help: <mailto:cygwin-help AT sources DOT redhat DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT sources DOT redhat DOT com
Delivered-To: mailing list cygwin AT sources DOT redhat DOT com
X-Authentication-Warning: hp2.xraylith.wisc.edu: khan owned process doing -bs
Date: Sat, 10 Mar 2001 16:09:40 -0600 (CST)
From: Mumit Khan <khan AT NanoTech DOT Wisc DOT EDU>
To: John Andrews <john AT triscend DOT com>
cc: cygwin AT cygwin DOT com
Subject: RE: cross compiler for Cygwin
In-Reply-To: <2407239113CD914CBA855A47698F01B0F544@SUGAH2.triscend.com>
Message-ID: <Pine.HPP.3.96.1010310160439.17015A-100000@hp2.xraylith.wisc.edu>
MIME-Version: 1.0

On Sat, 10 Mar 2001, John Andrews wrote:

> I think it's led to the problem.
> 
> In the file /usr/include/w32api/winnt.h line 2266 there's a typedef:
> 
> typedef struct _IMAGE_IMPORT_BY_NAME {
>         WORD Hint;
>         BYTE Name[1];
> } IMAGE_IMPORT_BY_NAME,*PIMAGE_IMPORT_BY_NAME;
> 
> When I found this definition in the prefix.i it had been altered:
> 
> typedef struct _IMAGE_IMPORT_BY_NAME {
>         WORD int  ;
>         BYTE Name[1];
> } IMAGE_IMPORT_BY_NAME,*PIMAGE_IMPORT_BY_NAME;
> 
> WORD Hint; is changed to WORD int ;

This is a problem with arm header files in gcc, which defines a macro
named "Hint", and that's what causes this problem. Windows API pollutes
user namespace in a horrible way, and makes life a lot harder that it
needs to be. Here's a quick workaround: replace all instances of "Hint" 
in gcc/config/arm/arm.[ch] files with something else (eg Hint->ARM_HINT) 
and rebuild.

> I had read several of your other how-tos but somehow I missed cygwin ->
> linux. I read through that and the run time libraies and headers are a major
> thing I'm missing. I'm trying to find a prebuilt version for my target to
> fill in the blanks. Do you think this is the?

You can do it one of two ways:
 
1. build glibc with some dummy (such as empty) stdio.h and stdlib.h
   headers, install, and then use that to build gcc.
2. install the prebuilt runtime from a linux machine, and that's the
   method I've outlined in my howto. 

Method 1 can be easy or hard depending on how well you understand glibc
setup, which is non-trivial.

Regards,
Mumit



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

- Raw text -


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