| Dear Akim,

Hi!

| My reasoning was as follows: $ac_arg is "-YP,[something]".
| Theerefore, sed -e 's%^P,%-L%" won't substitute anything, because the "P"
| is not at the beginning of the expression:
| 
| echo '-YP,/usr/bogus:/usr/stuff' | sed -e 's%^P,%-L%' -e 's%:% -L%g'
| -YP,/usr/bogus -L/usr/stuff
| 
| echo '-YP,/usr/bogus:/usr/stuff' | sed -e 's%^-YP,%-L%' -e 's%:% -L%g'
| -L/usr/bogus -L/usr/stuff
| 
| the latter is what we want, right?

Yep, definitely.  (First disclaimer: I don't master this code, and
didn't look at it very closely to be absolutely sure of myself).

But my point is that the previous code was ready to handle things you
no longer do.  Maybe that was a mistake, maybe not.  You should track
this macro in the ChangeLog to see who is the right person to ask for
details.

A quick guess it that the previous case was made to catch the case
where there is an space between the -Y and the P:

~ % echo 'P,/usr/bogus:/usr/stuff' | sed -e 's%^P,%-L%' -e 's%:% -L%g'
-L/usr/bogus -L/usr/stuff
~ % echo 'P,/usr/bogus:/usr/stuff' | sed -e 's%^-YP,%-L%' -e 's%:% -L%g'
P,/usr/bogus -L/usr/stuff

But then, maybe I'm missing something obvious :(

Reply via email to