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 Date: Sun, 21 Jul 2002 13:00:10 -0400 From: Christopher Faylor To: cygwin AT cygwin DOT com Subject: Re: g++ (v.3.1.1-4) -mno-cygwin with a hello world sample crashes oddly Message-ID: <20020721170010.GB1183@redhat.com> Reply-To: cygwin AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com References: <1465209200 DOT 20020721094429 AT familiehaase DOT de> <5 DOT 1 DOT 0 DOT 14 DOT 2 DOT 20020721075253 DOT 02c77d90 AT pop3 DOT cris DOT com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <5.1.0.14.2.20020721075253.02c77d90@pop3.cris.com> User-Agent: Mutt/1.3.23.1i On Sun, Jul 21, 2002 at 08:00:48AM -0700, Randall R Schulz wrote: >If you remove the ".exe" extension from a binary executable, it gets >treated like a script. Very few binaries are valid script files... > >When you use the "-c" option, you suppress the whole linking phase. The >output, regardless of its extension, is not a binary executable, it's an >object file. If you run the "file" command on your "hiho.exe" or its >earlier name: "hiho," you'll see something like this: > >% g++ -c hiho.cpp >% file hiho.o >hiho.o: 80386 COFF executable not stripped - version 30821 > > >Contrast: > >% g++ hiho.cpp -o hiho.exe >% file hiho.exe >hiho.exe: MS Windows PE Intel 80386 console executable not relocatable Wow, all of this traffic and Randall is the first, AFAICT, to notice that someone was using the -c option incorrectly. When I did my test case, I actually correctly did not use the -c option to try to create an executable and I never noticed the cockpit error. There are something on the order of 22 messages in this thread and it looks like only one person actually noticed the obvious problem. >Lastly: > >% g++ -mno-cygwin hiho.cpp -o hiho.exe >hiho.cpp:2: iostream: No such file or directory I suspect that this particular problem is probably due to the fact that you haven't installed the latest gcc-mingw package. cgf -- 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/