From nobody Mon Jan 12 17:18:41 2026 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4dqfH563dyz6NrRp for ; Mon, 12 Jan 2026 17:18:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R13" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4dqfH52p8Zz40cP for ; Mon, 12 Jan 2026 17:18:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1768238321; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=oqs2qvmpYYV7ZiXMKbZuHtf8yRvbNczZex8JiwZ6lDc=; b=FJ9/zBKI5BDVCjt72gjwe549QxpoAEAd1V8V95kwqLOjrfjXjTNEf3buPMXRSfH/CUCIKp dkteNi1N3WQxsMSAC1KFmLQCPfU/91M1wTF0rMxtfZwwFftZnrmx7uI+xsiappYY5IhoFB JjfRe3tARmFmJ+Vq9ojm9tQ8ltRXTO7QSwxuBk4PWaHnX1fXQ4tTPan7oo/dKzPRylSc9d sHXiVdMalfqygw8+S6M3v2/ALuggQ+Jnt6NYc1OuciDUhp6zrWZRS5bsJEWzqKe3UDjahb an0clwRE/9F54rTX9JUwpX/njcQDVW3KIUa9PpcG7YStRhRB2WqFasm8Z1EKyA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1768238321; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=oqs2qvmpYYV7ZiXMKbZuHtf8yRvbNczZex8JiwZ6lDc=; b=A8uUwpKytlJJgyJBYGyOGZaKjwIcWG6D9RQxo3g7cgo8xbwCegfHr0btXB8Z9DJDvezMW9 UW01wWLlCMRtxxPajT6XEdd08D8Fj0JaBUwiMMiXmW+O3MkVPz8UtSP0+jmmSeY6M4AtnV IyoxrtV7XfkhuJ9MGAjR08NniMRNWTHguMyF2+p0QsYpjrymxcKsNw97OCuPp2+gyXmkt7 /TKEV0IhhpDyS2GpNbXPH9AH9+c6z1QYk67KwJj8Z3E1qhA5qtiJI9A+nXv8EFNwYjZ54u QtA75bjyp2pM3fzYbn+Al4dtpNZr6nf1eiPGIA88XcIMacvkR60Tpn29Ix0gCA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1768238321; a=rsa-sha256; cv=none; b=BCqlruSElj8TrDdJjKEssm1ISmuUEzFSUnMCnwmLwTBLdKfLliam6kcSGlQHcXMOxCEUDJ WIuFmuUWm7D54OIgOZJk241d82jts1lcJwuBkQJvPSWPbpTOGTpMlxPoLYukEiB/CE7qki g9yXnueUpcMoenGjJISZumgRz0UkLVmIF2jScwgqzyUxP4i0X4iEqvmx6iJLPCOjxq67ys w9ccSl90b/OItLlpo9uIUSi3DYJw0uBWgqyZRiAx5jGMVZvQOEsNfWcg2tfJpKKkgXq2Xs jE1zkGu7c+DTFXwu6QXGGt9Kxa/CTXKGBDTKrGbvtBAyf8yKCU94mXLwrHlRNw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4dqfH525VVzcBC for ; Mon, 12 Jan 2026 17:18:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 37730 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Mon, 12 Jan 2026 17:18:41 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dag-Erling=?utf-8?Q? Sm=C3=B8rg?=rav Subject: git: d97fa8e49a4a - stable/15 - depend-cleanup.sh: Reduce repetition List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: des X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: d97fa8e49a4ad7134e6b5ba4f3aa4e262062256b Auto-Submitted: auto-generated Date: Mon, 12 Jan 2026 17:18:41 +0000 Message-Id: <69652cf1.37730.4dd6a1e0@gitrepo.freebsd.org> The branch stable/15 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=d97fa8e49a4ad7134e6b5ba4f3aa4e262062256b commit d97fa8e49a4ad7134e6b5ba4f3aa4e262062256b Author: Dag-Erling Smørgrav AuthorDate: 2025-12-31 13:10:39 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2026-01-12 17:18:21 +0000 depend-cleanup.sh: Reduce repetition MFC after: 1 week Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D54329 (cherry picked from commit aa611fa7e835ae77a623cc6d05020f5ee76dc881) --- tools/build/depend-cleanup.sh | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/tools/build/depend-cleanup.sh b/tools/build/depend-cleanup.sh index 2e52262693e5..403b0823a2b6 100755 --- a/tools/build/depend-cleanup.sh +++ b/tools/build/depend-cleanup.sh @@ -161,13 +161,13 @@ run() # $4 optional regex for egrep -w clean_dep() { + local dirprfx dir for libcompat in "" $ALL_libcompats; do - dirprfx=${libcompat:+obj-lib${libcompat}/} - if egrep -qw "${4:-$2\.$3}" "$OBJTOP"/$dirprfx$1/.depend.$2.*o 2>/dev/null; then + dirprfx=${libcompat:+obj-lib${libcompat}} + dir="${OBJTOP%/}/${dirprfx}/$1" + if egrep -qw "${4:-$2\.$3}" "${dir}"/.depend.$2.*o 2>/dev/null; then echo "Removing stale ${libcompat:+lib${libcompat} }dependencies and objects for $2.$3" - run rm -fv \ - "$OBJTOP"/$dirprfx$1/.depend.$2.* \ - "$OBJTOP"/$dirprfx$1/$2.*o + run rm -fv "${dir}"/.depend.$2.* "${dir}"/$2.*o fi done } @@ -183,12 +183,13 @@ clean_dep() # $4 regex for egrep -w clean_obj() { + local dirprfx dir for libcompat in "" $ALL_libcompats; do - dirprfx=${libcompat:+obj-lib${libcompat}/} - if strings "$OBJTOP"/$dirprfx$1/$2.*o 2>/dev/null | egrep -qw "${4}"; then + dirprfx=${libcompat:+obj-lib${libcompat}} + dir="${OBJTOP%/}/${dirprfx}/$1" + if strings "${dir}"/$2.*o 2>/dev/null | egrep -qw "${4}"; then echo "Removing stale ${libcompat:+lib${libcompat} }objects for $2.$3" - run rm -fv \ - "$OBJTOP"/$dirprfx$1/$2.*o + run rm -fv "${dir}"/$2.*o fi done } @@ -221,6 +222,7 @@ extract_src_opts() extract_obj_opts() { + local fn for fn; do if [ -f "${fn}" ]; then cat "${fn}"