Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com X-Authentication-Warning: smtp3.cern.ch: Host pb-d-128-141-36-121.cern.ch [128.141.36.121] claimed to be lxcms60.cern.ch Message-ID: <3E70D5C7.70300@cern.ch> Date: Thu, 13 Mar 2003 20:02:31 +0100 From: "Lassi A. Tuura" Organization: Northeastern University, Boston, USA User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2) Gecko/20030129 X-Accept-Language: en-us, en MIME-Version: 1.0 To: cygwin AT cygwin DOT com Subject: GCC 3.2.2 linux to cygwin,mingw32 cross compiler? Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Hi, Is there a receipe for building a linux-hosted cygwin/mingw32 GCC 3.2.2 (or any 3.2+) cross compiler for C and C++? For linux-x-mingw32 I did and for linux-x-cygwin . Building GCC 3.2.2 linux-x-cygwin took a few tweaks in libiberty and choosing the right top-level include contents, but otherwise it went fine. I can post the exact receipe in case it matters. I noticed that with -mno-cygwin it prefers i686-pc-cygwin/include over i686-pc-cygwin/include/mingw (e.g. io.h, but there are others, and it finds unistd.h etc.). I got around some of those by changing specs in gcc/config/i386/cygwin.h to -isystem instead of -idirafter the mingw include dir. (BTW, it didn't find crt.o with the -L option either, I added the full path in the specs file.) With those changes C++ is not happy however. libstdc++ assumes cygwin's newlib ctype.h but gets mingw/ctype.h, with lots of messages of type: .../include/c++/3.2.2/i686-pc-cygwin/bits/ctype_base.h:46: `_U' was not declared in this scope Is this currently known to be broken or did I screw it up with the above changes to specs? Is there an easy fix? Would this require multilib magic for libstdc++ for -mno-cygwin? In short, is it possible to have one cross chain to compile both cygwin and mingw32 programs (latter with -mno-cygwin), or should I keep the two separate chains? I realise -mno-cygwin is a cygwin cross environment already. If someone says this "cross of a cross" won't work, that's ok with me, I just want to know I am not responsible for cockpit errors :-) //lat -- Ambition, n.: An overmastering desire to be vilified by enemies while living and ridiculed by friends when dead. --Ambrose Bierce -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Bug reporting: http://cygwin.com/bugs.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/