Source-Changes-D archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: CVS commit: src/regress/sys/net



On Thu, Mar 03, 2011 at 12:27:19AM +0000, David Holland wrote:
> On Tue, Mar 01, 2011 at 08:02:40AM +0000, David Laight wrote:
>  > > autogen requires ed(1), which is not provided by our toolchain.
>  > > (In other words, this causes a odd build failure on some Linux build
>  > > hosts.)
>  > 
>  > I've not looked, but it is probably not too hard to change the script
>  > to use a different tool.
>  > (Possibly just a shell script)
> 
> This should do the trick, modulo feeding in ${TOOL_AWK} properly:
> 
...
> +awk < $1 '
> +    state == 0 && /^ether_aton_r/ { print prev; state = 1; }
> +    state == 1 { print; }
> +    state == 1 && /^}$/ { state = 2; }
> +    { prev = $0; }
> +' >> $2

Looks like that would be even simpler in sed :-)

        David

-- 
David Laight: david%l8s.co.uk@localhost


Home | Main Index | Thread Index | Old Index