Open DoctorNoobingstoneIPresume opened 1 year ago
I have tried "non-greedy repetition" by changing .*=
to .*?=
:
echo "--prefix=xxx=yyy" | sed s'/.*?=//'
but it does not seem to work for me.
I wish we could create a function which executes echo $1 | sed 's/[^=]*=//
and call it instead of repeating the code in the processing of --prefix=
, --eprefix=
, --libdir=
, --sharedlibdir=
, --includedir=
, --uname=
, --archs=
etc.
@madler: Can you look this PR?
The user is allowed to specify directory pathnames using --prefix=PATHNAME etc., but the extraction of the PATHNAME used to use a regex which eliminated everything until the last equals sign.
We have switched to eliminating everything until the first equals sign.