This is the mail archive of the cygwin@sourceware.cygnus.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: No error messages from mingw32 gcc.exe


Pierre Dolmans wrote:
> 
> Hi,
> 
> I have a program running on Cygwin32, but for several reasons I want to
> switch to Mingw32 now. Therefore I have installed Mingw32, and changed my
> environment variables in accordance with the installation documentation.
[skip]
> 
> However, if a compile fails, I don't see the error messages from the
> compiler, but just get the make output that looks like this:
 
 Yes, it's a strange bug. You can't see stdio and stderr output from any
mingw
program linked with crtdll.dll, when it runs under cygwin shell. There
are three ways
to circumvent it:

1. hard way. Modify mingw gcc specs file and rebuild mingw gcc,
libraries and binutils 
   so that they will link with msvcrt.dll, not crtdll. 
2. easy way. Use cygwin gcc to produce code for mingw target. Set
GCC_EXEC_PREFIX to
   where your .../mingw/lib/gcc-lib lies, and make sure that mingw
binutils are used 
   by gcc - put them in GCC_EXEC_PREFIX/i386-cygwin32/2.7-B19 or
somewhere in PATH before 
   cygwin binutils. You will not see any errors from mingw ld, though.
3. ugly way. Use as compiler windows batch file which runs gcc and
redirects its output
   to file. Under nt you will need to use renamed cmd.exe, because
cygwin shell goes mad 
   if you attempt to run cmd from it.
-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]