From: Alexandru Ardelean Date: Tue, 28 Jul 2026 12:37:50 +0000 (+0300) Subject: pv: update to 1.11.0 X-Git-Url: http://git.99rst.org/?a=commitdiff_plain;h=833d665fe3bd6a4803ddd71bf70d9b77ead8d56f;p=openwrt-packages.git pv: update to 1.11.0 Update to the latest upstream stable release and add a functional test.sh that pipes a small text stream and a 256 KiB binary stream through pv, checking both arrive unchanged. Signed-off-by: Alexandru Ardelean --- diff --git a/utils/pv/Makefile b/utils/pv/Makefile index 2898062fb..388a094ab 100644 --- a/utils/pv/Makefile +++ b/utils/pv/Makefile @@ -9,12 +9,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=pv -PKG_VERSION:=1.9.31 -PKG_RELEASE:=2 +PKG_VERSION:=1.11.0 +PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://www.ivarch.com/programs/sources -PKG_HASH:=a35e92ec4ac0e8f380e8e840088167ae01014bfa008a3a9d6506b848079daedf +PKG_HASH:=fc02c9fc2b82b20a92cc8d98f844be63f22abd98751a8e4abc875e1d803662eb PKG_LICENSE:=GPL-3.0-or-later PKG_LICENSE_FILES:=docs/COPYING PKG_MAINTAINER:=Alexandru Ardelean diff --git a/utils/pv/test.sh b/utils/pv/test.sh new file mode 100644 index 000000000..c45cc1082 --- /dev/null +++ b/utils/pv/test.sh @@ -0,0 +1,19 @@ +#!/bin/sh +# pv must copy a stream through the pipe unchanged. + +[ -x /usr/bin/pv ] || { echo "FAIL: /usr/bin/pv not installed"; exit 1; } + +# text stream +payload="pv basic functionality test 0123456789" +out="$(printf '%s' "$payload" | pv -q)" +[ "$out" = "$payload" ] || { echo "FAIL: pv altered a text stream"; exit 1; } + +# 256 KiB binary stream: checksum must survive the pipe +tmp="$(mktemp)" +head -c 262144 /dev/urandom > "$tmp" +in_sum="$(md5sum < "$tmp" | cut -d' ' -f1)" +out_sum="$(pv -q < "$tmp" | md5sum | cut -d' ' -f1)" +rm -f "$tmp" +[ "$in_sum" = "$out_sum" ] || { echo "FAIL: pv corrupted a 256 KiB stream"; exit 1; } + +echo "pv: stream pass-through OK"