[CMake] Causing cmake to use stderr instead of stdout.

2007-11-19 Thread Josef Karthauser
Is it possible (with relative easy) to have cmake send all output to
stderr instead of stdout?

 

Joe

___
CMake mailing list
CMake@cmake.org
http://www.cmake.org/mailman/listinfo/cmake

Re: [CMake] Causing cmake to use stderr instead of stdout.

2007-11-19 Thread Dizzy
On Monday 19 November 2007 18:37:02 Josef Karthauser wrote:
> Is it possible (with relative easy) to have cmake send all output to
> stderr instead of stdout?

Well on a bourne shell I think you can do:

cmake /path/to/sources 1>&2

And it will run cmake redirecting fd 1 (stdout) to fd 2 (stderr). If you need 
to further direct the output make sure you write that before "1>&2" part as 
in:

cmake /path/to/sources 2> logfile.txt 1>&2

-- 
Mihai RUSU  Email: [EMAIL PROTECTED]
"Linux is obsolete" -- AST
___
CMake mailing list
CMake@cmake.org
http://www.cmake.org/mailman/listinfo/cmake


RE: [CMake] Causing cmake to use stderr instead of stdout.

2007-11-19 Thread Josef Karthauser
:) Sure I can do that.  However I was trying to use 'dos'.  World of
pain.  Using cygwin's bourne shell instead :).

Joe

> -Original Message-
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] On
Behalf
> Of Dizzy
> Sent: 19 November 2007 16:48
> To: cmake@cmake.org
> Subject: Re: [CMake] Causing cmake to use stderr instead of stdout.
> 
> On Monday 19 November 2007 18:37:02 Josef Karthauser wrote:
> > Is it possible (with relative easy) to have cmake send all output to
> > stderr instead of stdout?
> 
> Well on a bourne shell I think you can do:
> 
> cmake /path/to/sources 1>&2
> 
> And it will run cmake redirecting fd 1 (stdout) to fd 2 (stderr). If
> you need
> to further direct the output make sure you write that before "1>&2"
> part as
> in:
> 
> cmake /path/to/sources 2> logfile.txt 1>&2
> 
> --
> Mihai RUSUEmail: [EMAIL PROTECTED]
>   "Linux is obsolete" -- AST
> ___
> CMake mailing list
> CMake@cmake.org
> http://www.cmake.org/mailman/listinfo/cmake
___
CMake mailing list
CMake@cmake.org
http://www.cmake.org/mailman/listinfo/cmake


Re: [CMake] Causing cmake to use stderr instead of stdout.

2007-11-19 Thread David Cole
By 'dos' I assume you mean the cmd prompt for Windows 2000, XP or Vista...?You
can just as easily use 2>&1 syntax in there also.

cmake --help 1>cmake1.txt 2>cmake2.txt
cmake --help 2>cmake2.txt 1>&2

works just fine from a 'dos' prompt on Win2k or later...



On 11/19/07, Josef Karthauser <[EMAIL PROTECTED]> wrote:
>
> :) Sure I can do that.  However I was trying to use 'dos'.  World of
> pain.  Using cygwin's bourne shell instead :).
>
> Joe
>
> > -Original Message-
> > From: [EMAIL PROTECTED]
> > [mailto:[EMAIL PROTECTED] On
> Behalf
> > Of Dizzy
> > Sent: 19 November 2007 16:48
> > To: cmake@cmake.org
> > Subject: Re: [CMake] Causing cmake to use stderr instead of stdout.
> >
> > On Monday 19 November 2007 18:37:02 Josef Karthauser wrote:
> > > Is it possible (with relative easy) to have cmake send all output to
> > > stderr instead of stdout?
> >
> > Well on a bourne shell I think you can do:
> >
> > cmake /path/to/sources 1>&2
> >
> > And it will run cmake redirecting fd 1 (stdout) to fd 2 (stderr). If
> > you need
> > to further direct the output make sure you write that before "1>&2"
> > part as
> > in:
> >
> > cmake /path/to/sources 2> logfile.txt 1>&2
> >
> > --
> > Mihai RUSUEmail: [EMAIL PROTECTED]
> >   "Linux is obsolete" -- AST
> > ___
> > CMake mailing list
> > CMake@cmake.org
> > http://www.cmake.org/mailman/listinfo/cmake
> ___
> CMake mailing list
> CMake@cmake.org
> http://www.cmake.org/mailman/listinfo/cmake
>
___
CMake mailing list
CMake@cmake.org
http://www.cmake.org/mailman/listinfo/cmake

Re: [CMake] Causing cmake to use stderr instead of stdout.

2007-11-19 Thread Jesper Eskilson
Dizzy wrote:
> On Monday 19 November 2007 18:37:02 Josef Karthauser wrote:
>> Is it possible (with relative easy) to have cmake send all output to
>> stderr instead of stdout?
> 
> Well on a bourne shell I think you can do:
> 
> cmake /path/to/sources 1>&2
> 
> And it will run cmake redirecting fd 1 (stdout) to fd 2 (stderr). If you need 
> to further direct the output make sure you write that before "1>&2" part as 
> in:
> 
> cmake /path/to/sources 2> logfile.txt 1>&2

cmd.exe has limited support for sh-style redirections, so I think you
can do things like

   cmake c:/my/sources >log.txt 2>&1

in your regular windows command prompt.

--
/Jesper



___
CMake mailing list
CMake@cmake.org
http://www.cmake.org/mailman/listinfo/cmake