commit: 1cea73eae5768915086a7891628438865d7664df Author: orbea <orbea <AT> riseup <DOT> net> AuthorDate: Sun Jul 16 16:37:51 2023 +0000 Commit: orbea <orbea <AT> riseup <DOT> net> CommitDate: Sun Jul 16 16:37:51 2023 +0000 URL: https://gitweb.gentoo.org/repo/proj/libressl.git/commit/?id=1cea73ea
dev-lang/rust: don't use grep -P Closes: https://github.com/gentoo/libressl/issues/534 Signed-off-by: orbea <orbea <AT> riseup.net> dev-lang/rust/files/rehash-crate.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dev-lang/rust/files/rehash-crate.sh b/dev-lang/rust/files/rehash-crate.sh index 8f738b7..1ffd775 100644 --- a/dev-lang/rust/files/rehash-crate.sh +++ b/dev-lang/rust/files/rehash-crate.sh @@ -7,8 +7,8 @@ cargo='.cargo-checksum.json' grep -- '+++' "${1:?}" | while read -r _ f; do file="${f#*/}" - orig_sum="$(grep -Po "(?<=\"${file}\":\")[0-9a-fA-F]+(?=\")" \ - "${cargo}")" + orig_sum="$(grep -Eo "\"${file}\":\"[0-9a-fA-F]+\"" "${cargo}" | + cut -d':' -f2 | tr -d '"')" if [ -n "${orig_sum}" ]; then sum="$(sha256sum "${file}")" sed -i "s|${orig_sum}|${sum%% *}|" "${cargo}"
