A brief lesson on redirecting output.
make depend 2> logfile.txt
This will redirect standard error to the file "logfile.txt".
make depend > logfile.txt
This will redirect standard output to the file "logfile.txt".
make depend > logfile.txt 2>&1
This will redirect both standard error and standard output to the file
"logfile.txt". Note that in this case, the "> logfile.txt" _must_ come before
the "2>&1".
Most programs send their error messages to standard error, but occasionally an
application may be programmed to send it's error messages to standard output
instead. Some non-error messages may also be useful in debugging an error as
well. As such, it is advisable to trap both the standard error as well as the
standard output.
On 02-Dec-98 Jeremy Wiebe wrote:
> Hi all,
>
> I am trying to compile the diald program. I have downloaded it, but when I
> do a "make depend" as the README suggests, make complains about multiple
> declerations. I know there is a way to trap these messages but I can't
> remember how and I can't find it anywhere for the life of me. I seem to
> remember something like "make depend 2>&1 logfile.txt"
>
> Not sure if someone has had this same problem, but the essence of the
> warnings are that there are symbols that are being defined in more than one
> header file. I was going to give the output, but alas, I need the answer to
> the first part before I can ask the second I guess.
>
>
> ------------------------------------------------------
> Another message from Jer Wiebe
>
> Find me at...
> email: [EMAIL PROTECTED]
> ICQ: 4945359
Cort
[EMAIL PROTECTED]