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: Fri, 7 Feb 2003 07:27:19 -0800 From: Dario Alcocer To: cygwin AT cygwin DOT com Subject: Re: Problems compiling trivial C program. Message-ID: <20030207072719.A19046@ns.helixdigital.com> References: <20030207133340 DOT atomice AT plus DOT net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i In-Reply-To: <20030207133340.atomice@plus.net>; from chris@atomice.net on Fri, Feb 07, 2003 at 01:33:40PM -0000 On Fri, Feb 07, 2003 at 01:33:40PM -0000, Christopher January wrote: > I'm having trouble compiling this test program: > > void f(){} > > using the command line: > gcc test.c -c -o test.o > > using 1.3.19 or latest Cygwin snapshot (2003-Feb-07) (same error with > both) and gcc-3.2-3. > > The error I see is: > > 16 bit MS-DOS Subsystem > /usr/src/cygwin-cvs/obj > The NTVDM CPU has encountered an illegal instruction. > CS:0000 IP:0077 OP:f0 37 05 0e 02 Choose 'Close' to terminate the > application. > Close | Ignore I've seen these errors myself in the past, all associated with running configure and/or gcc. For some reason, NT is trying to invoke the NT Virtual DOS Machine (NTVDM) when it runs gcc.exe. The problem is that gcc.exe should be identified as a Win32 console application, and therefore doesn't need NTVDM to run. I wonder if there's some sort of memory corruption going on that results in gcc.exe being identified as a 16-bit mode DOS program, like maybe the NE stub in the PE file being scribbled by an errant pointer. Maybe something in the NE stub in the actual disk file for gcc.exe has some bits that inadvertently set of NTVDM. Anyway, you can try the following hack that might allow you to run the compiler (that is, as long as you don't try to run any DOS apps under NT): http://www.rtems.com/rtems/maillistArchives/rtems-users/2001/june/msg00182.html There's additional information in this MSDN KnowledgeBase article: http://support.microsoft.com/default.aspx?scid=KB;en-us;q196453 -- Dario Alcocer -- Sr. Software Developer, Helix Digital Inc. alcocer AT helixdigital DOT com -- http://www.helixdigital.com -- 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/