This is the mail archive of the
cygwin
mailing list for the Cygwin project.
Re: [NEARLY SOLVED:] Re: make producing basename error that can't be captured by "make &> make.out"
- From: Dave Korn <dave dot korn dot cygwin at gmail dot com>
- To: cygwin at cygwin dot com
- Date: Fri, 02 Mar 2012 06:50:57 +0000
- Subject: Re: [NEARLY SOLVED:] Re: make producing basename error that can't be captured by "make &> make.out"
- Authentication-results: mr.google.com; spf=pass (google.com: domain of dave.korn.cygwin@gmail.com designates 10.216.138.131 as permitted sender) smtp.mail=dave.korn.cygwin@gmail.com; dkim=pass header.i=dave.korn.cygwin@gmail.com
- References: <4F5035D0.9070502@cs.cmu.edu> <4F506393.1030502@gmail.com> <4F5067E0.5000203@cs.cmu.edu>
On 02/03/2012 06:25, Paul Allen Newell wrote:
> +++
> type make; which -a make
> make is aliased to `settitle Making $(basename $PWD) && make "$@"'
> /usr/bin/make
> /usr/bin/make
> +++
>
> I groaned when I saw this as it is obvious the $(PWD) is feeding
> basename and that's the "make" error. Thanks.
>
> However, I am still trying to understand why this potentially incorrect
> alias is creating text output to the screen which can't be redirected as
> it isn't stdout or stderr ... or "3/4/5" as someone suggested I test.
I think it's because aliases are just simple text substitutions. So if you
have 'make' being transformed to 'settitle Making $(basename $PWD) && make
"$@"' then you would get 'make >& make.out' becoming 'settitle Making
$(basename $PWD) && make "$@" >& make.out' and as you see the redirect only
gets applied to the command after the '&&'.
cheers,
DaveK
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple