On Thu, 11 Dec 2003 07:42:25 +0100, Jan Kratochvil wrote: > I found out now that 'break' is documented by "Limitations of Shell > Builtins" as compatible, therefore here is a patch copying the permissions > of the FIRST file of $ac_file_inputs. > + rm -f $ac_file > +dnl Keep 'executable' attribute. > + for f in $ac_file_inputs; do > + cp $f $ac_file > + chmod u+w $ac_file > + break > + done > + cat $tmp/out >$ac_file This looks fine to me. Perhaps change the comment to "Propagate 'executable' attribute of first input file." Note also that you can access the first element of $ac_file_inputs as so: ac_first_input=`set X $ac_file_inputs; echo $[2]` It is a question of personal test whether this is a clearer or more obscure method of accessing the first file. It is certainly a bit slower since it invokes a subshell. (Note that the $[2] becomes $2 in the generated configure script.) -- ES