From 4e2eb9922e9e7c43ed2345afa9728f7d216a847f Mon Sep 17 00:00:00 2001 From: llmII Date: Tue, 3 Jan 2023 18:44:55 -0600 Subject: [PATCH] Fix checksum virtualenv checks. There's already precedence for not using GNUism sha256sum longopts as seen in searxng/utils/lib_go.sh so update lib.sh to not use them either. A nice side effect is now the sha256sum usage doesn't care if you're using BSD sha256sum or GNU sha256sum which makes this work under FreeBSD. --- utils/lib.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utils/lib.sh b/utils/lib.sh index a4e9e852..afc6ef19 100755 --- a/utils/lib.sh +++ b/utils/lib.sh @@ -600,7 +600,7 @@ pyenv.OK() { fi if [ ! -f "${PY_ENV}/requirements.sha256" ] \ - || ! sha256sum --check --status <"${PY_ENV}/requirements.sha256" 2>/dev/null; then + || ! sha256sum -c "${PY_ENV}/requirements.sha256" > /dev/null 2>&1; then build_msg PYENV "[virtualenv] requirements.sha256 failed" sed 's/^/ [virtualenv] - /' <"${PY_ENV}/requirements.sha256" return 1