Page MenuHomePhabricator

build: improve sed robustness by not using sed
ClosedPublic

Authored by Fabien on Oct 5 2020, 13:17.

Details

Reviewers
majcosta
Group Reviewers
Restricted Project
Commits
rABC67f690d306a4: build: improve sed robustness by not using sed
Summary
While using sed can be handy to use for a quick-fix, these instances
accumulate, and can become unmaintainable. Not only that, but using sed
isn't necessarily robust and it can fail silently. Most of our usage is
also missing any documentation explaining why something is being done,
when it should be updated/removed etc.

Rather than relying on sed going forward, where possible, I've converted
our sed usage into patches. These are easier to maintain, contain
documentation, and should fail loudly when they don't apply.

The remaining sed usage, (1 in miniupnpc, the rest in qt), are
non-trivial to remove, as they are using build-time variables, or some
input from the environment.

Backport of core PR19761, slightly updated to match our depends.

Depends on D7760.

Test Plan
make build-all

Event Timeline

Fabien requested review of this revision.Oct 5 2020, 13:17

[Bot Message]
One or more PR numbers were detected in the summary.
Links to those PRs have been inserted into the summary for reference.

This revision is now accepted and ready to land.Oct 5 2020, 14:53