delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/1999/01/07/18:26:39

From: khan AT xraylith DOT wisc DOT edu (Mumit Khan)
Subject: Re: Mingw32 egcs 1.1.1, GCC_EXEC_PREFIX and CreateProcess
7 Jan 1999 18:26:39 -0800 :
Message-ID: <Pine.SUN.3.93.990107093256.7049C-100000.cygnus.gnu-win32@modi.xraylith.wisc.edu>
References: <199901042036 DOT VAA02870 AT wanadoo DOT fr>
Mime-Version: 1.0
To: Gilles Depeyrot <Gilles DOT Depeyrot AT wanadoo DOT fr>
Cc: gnu-win32 AT cygnus DOT com

On Mon, 4 Jan 1999, Gilles Depeyrot wrote:

> I'm having a problem with Mingw32 egcs-1.1.1 concerning the
> GCC_EXEC_PREFIX environment variable.
> 
> I launch and run egcs from inside an Win32 application using
> a call to CreateProcess. This works fine except for the fact
> that in this case, GCC_EXEC_PREFIX *must* be defined or I get
> an error message:
> 
> gcc: installation problem, unable to exec `cpp'

Gilles,

I believe I've finally tracked the bug down (and fixed it)! Depending on
the shell or method invocation, argv[0] may or may not have .exe and
that's where the trouble is:
  
  - command      : ``gcc'' -- > argv[0] == 'c:\egcs-1.1.1\gcc.exe'
  - cmd          : ``gcc'' -- > argv[0] == 'c:\egcs-1.1.1\gcc.exe'
  - bash         : ``gcc'' --> argv[0] == 'gcc' 
  - CreateProcess : no implicit .exe appendage 

It always worked for command.com because it always expands the full path
and puts it in argv[0]!

Could you try a quick experiment: Try to execute gcc.exe as opposed to gcc
via CreateProcess; if it works, then I have found the problem and I can
work up an update.

Regards,
Mumit


-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request AT cygnus DOT com" with one line of text: "help".

- Raw text -


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