[PR #627] Work around Linuxisms #1277

Open
opened 2026-01-29 20:53:18 +00:00 by claunia · 0 comments
Owner

Original Pull Request: https://github.com/google/brotli/pull/627

State: closed
Merged: Yes


Missed this in my previous tests. Sorry for that.

On BSDs, both bc and sed are part of the base operating system. For sed this results in an error as the check construct (--version) is a GNU-ism and only works for GNU sed, not for bsd sed.
Similarly, BSD sed does not take parameters after the filename(s) operated on. Moving -i to the front fixes that. -r is provided for GNU compat in BSD sed as an alias of -E. The -i option in BSD sed requires an extension to work in-place.

(thank you for picking up the nginx module too!)

**Original Pull Request:** https://github.com/google/brotli/pull/627 **State:** closed **Merged:** Yes --- Missed this in my previous tests. Sorry for that. On BSDs, both bc and sed are part of the base operating system. For sed this results in an error as the check construct (--version) is a GNU-ism and only works for GNU sed, not for bsd sed. Similarly, BSD sed does not take parameters after the filename(s) operated on. Moving `-i` to the front fixes that. `-r` is provided for GNU compat in BSD sed as an alias of `-E`. The `-i` option in BSD sed requires an extension to work in-place. (thank you for picking up the nginx module too!)
claunia added the pull-request label 2026-01-29 20:53:18 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/brotli#1277