undefined references for GUI library using Mingw32

Charles Wilson cwilson@ee.gatech.edu
Fri Apr 30 18:32:00 GMT 1999


dale henderson wrote:

> >But where is the problem report????  I don't have the time to go
> >through
>
> I am not able to pipe the errors msgs from the compile to a file.
> Here is an example:
>

make >& file

will redirect both stdout and stderr of make (and everything called by
make, such as gcc) to a file. 'Course, you won't see anything in your
terminal window...

So, you could try the following:

make 2>&1 | tee file

which (1) sets up a pipe to tee.exe -- i.e. stdout from make now points to
stdin of tee (2) makes filedescriptor 2 (stderr) of make go to wherever
filedescriptor 1 (stdout) is currently pointing -- which is the stdin of
tee. Thus, tee gets both stdout and stderr. Tee is a program which copies
its stdin to a file, and to stdout; it's distributed with cygwin.

Cmd.exe also lets you do redirection in this manner, but you need either a
native version of tee, or you can use the cygwin version of tee, but then
things get hairy with path specifiers ( '/' vs '\'. I suppose you could use
cygpath somehow). You can get a native port of tee (and ports of a lot of
other gnu-ish stuff) from
http://www.edv.agrar.tu-muenchen.de/~syring/win32/UnxUtils.html . Also,
Anders Norlander has built mingw ports of a lot of gnu stuff - but not tee.

Command.com? Well...it doesn't do this kind of redirection, so you need an
external program, similar to the redir.exe that comes with djgpp. You can
get that program from
http://www.delorie.com/djgpp/dl/ofc/simtel/v2/djdev202.zip/bin/redir.exe ,
but it is intended for DOS and doesn't grok long filenames. I'm not sure
why that matters, since redir doesn't really _do_ anything with the LFN's
if they are there. Maybe it's related to the internal system() or spawnXX()
call in redir. I dunno - it mostly works. Try

redir -eo make | tee file

--Chuck






--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com




More information about the Cygwin mailing list