This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch] cleanup target makefile frag collection in toplevel


> 2002-05-22  Nathanael C. Nerode  <neroden@twcny.rr.com>
> 	* configure.in: Clean up target makefile fragment collection.

> --- 1302,1316 ----
>   fi
>   
>   rm -f mt-frag
> ! for f in ${target_makefile_frag} ${alpha_frag} ${ospace_frag} ; do
> !   if test $f != /dev/null ; then
>       cat ${srcdir}/$f >> mt-frag
> !   fi
> ! done
> ! if test -n "${target_makefile_frag}${alpha_frag}${ospace_frag}" ; then
>     target_makefile_frag=mt-frag
> + else
> +   target_makefile_frag=
>   fi
>   
>   case "$host" in
> 

Me thinks you need the "for" inside the "if test -n".  If all three
variables are empty, the for will fail with a syntax error.

You do, however, preset them all to /dev/null, which means the "if
test -n" will never be false, and is thus superfluous.  Although, on
platforms with no real /dev/null (I don't know of any at the moment,
but still), reading from /dev/null (a file) may give you back whatever
was thrown away last time output was redirected to /dev/null.

Could you pick one way or the other and update the patch?


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