Re: [PATCH 1/2] ld-version: use /usr/bin/env awk for shebank

From: 'Dominique Martinet'
Date: Thu Dec 10 2020 - 07:23:04 EST


Vincenzo Frascino wrote on Thu, Dec 10, 2020:
> On 12/9/20 10:03 PM, David Laight wrote:
>> Why bother with awk?

I wanted to keep the patch minimal, I'm not opposed to rewriting but
that always potentially has more impact (although as you say, this
script is simple enough)

> > I think you can do it all in a shell function.
> > Something like:
> > read line
> > line=${line##*)}
> > line=${line##*version }
> > IFS='.-'
> > set $line
> > echo $(($1*100000000 + $2*1000000 + $3*10000))
> >
> > That will work on any recent shell.

Works for me.


> I would suggest to revert the patch for now since we are close to the merge
> window and then maybe in -rc1 start discussing a better solution.

As far as I can see the patch is only in -next, as said earlier I'm in
favor of just dropping the patch until a decision is taken for the next
merge window (or the one after that); there's no hurry for me and
nothing to revert.

--
Dominique