delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2007/01/11/12:48:51

X-Spam-Check-By: sourceware.org
Message-ID: <45A677F5.66B6DCE2@dessent.net>
Date: Thu, 11 Jan 2007 09:46:29 -0800
From: Brian Dessent <brian AT dessent DOT net>
X-Mailer: Mozilla 4.79 [en] (Windows NT 5.0; U)
MIME-Version: 1.0
To: cygwin AT cygwin DOT com
Subject: Re: gcc: installation problem, cannot exec 'cc1'
References: <cf641f1d0701110905v665c15a0vcc5dc7292684ce3d AT mail DOT gmail DOT com> <cf641f1d0701110908k3860d349i96cf5af187ce654a AT mail DOT gmail DOT com>
X-IsSubscribed: yes
Reply-To: cygwin AT cygwin DOT com
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.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

Thomas Antony wrote:

>     This is my first post here. I recently installed Cygwin again
> after my harddisk crashed and had to be formatted and all. I mainly
> use an ELF cross compiler for doing OS dev. So it was when I tried to
> compile a simple app using the normal GCC that I ran into this error.
> 
> $ gcc -mno-cygwin -o hello hello.c
> gcc: installation problem, cannot exec 'cc1': No such file or directory
> 
> I see that it occurs only when I use the -mno-cygwin option. I
> searched google. I found I have to install gcc-mingw package. I
> installed it. But the problem still prevails. I also see that there is
> no /usr/lib/gcc-lib directory. I found  cc1.exe in the
> /lib/gcc/i686-pc-cygwin/3.4.4 directory. I tried adding that to the
> PATH. But then I get the error.

Don't do that.  It's not necessary and won't help.  When you specify
-mno-cygwin you switch to using MinGW's version of gcc, an entirely
separate version of gcc that is installed alongside the Cygwin version. 
This is why you must install the gcc-mingw-* packages for this to work. 
Incidently, I don't understand how you managed to at first install
gcc-core but *not* gcc-mingw-core, since gcc-core lists gcc-mingw-core
as a prerequisite in the setup.ini file (and so on for the other
languages), so selecting one should have selected the other, and
breaking this dependancy should have given you a big fat warning
message.

The cc1 that it is looking for when you use -mno-cygwin should be 
/usr/lib/gcc/i686-pc-mingw32/3.4.4/cc1.exe.  What does "ls -l
/usr/lib/gcc/i686-pc-mingw32/3.4.4/" show?  Did you have any problems
running the postinstall scripts?  Do you have any that are not renamed
.done?  What does "ls -l /etc/postinstall/gcc*" show?

> ld: crt2.o: No such file: No such file or directory

This is part of mingw-runtime, and should be present in /usr/lib/mingw.

Brian

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

- Raw text -


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