Commit 37aca8f5 authored by Christoph Berg's avatar Christoph Berg

pg_buildext: Handle multiple overlapping substitutions in debian/tests/control.in better.

If one substitution pattern matched several times, the next substitutions would fail.

Example:
Depends: @, postgresql-server-dev-all, postgresql-PGVERSION-pglogical, postgresql-PGVERSION-pglogical-ticker
parent dbd6eb64
Pipeline #26080 passed with stage
in 7 minutes and 38 seconds
......@@ -6,6 +6,8 @@ postgresql-common (196) UNRELEASED; urgency=medium
* Updated Turkish translation by Atila Koç, thanks! (Closes: #912322)
* read_conf_file: Accept '+' in unquoted values for floats like 1.5+e3.
Thanks to David Barbion for spotting!
* pg_buildext: Handle multiple overlapping substitutions in
debian/tests/control.in better.
[ Jeremy Bicha ]
* Add Ubuntu 19.04 aka disco.
......
......@@ -188,7 +188,8 @@ gencontrol() {
repl="${repl:+$repl, }$(echo $pkgpattern | sed -e "s/PGVERSION/$v/g")"
done
# put array into control file
sed -i -e "s/$pkgpattern/$repl/g" $tmptestscontrol
grep -q "$pkgpattern" $tmptestscontrol # assert the pattern didn't get already removed by an earlier replacement
sed -i -e "s/$pkgpattern/$repl/" $tmptestscontrol
done
fi
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment