From nobody Mon Dec 09 21:49:00 2024 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 4Y6b992nTRz5gqbm; Mon, 09 Dec 2024 21:49:01 +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 "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Y6b990Pqdz4HLl; Mon, 9 Dec 2024 21:49:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733780941; 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=IFVMyUHc1vQu1f29WShEPI1QukYsbyi4R7KVFVioWOQ=; b=yGm7Tq0kZD+3N6X7H1LESTTt7DGfweTfjFlsjZcxnnLtxgbFMXnyUkyMxGJmd4nNuEk2cJ C86xIRbSraZzlC2GYjDDn/iL3sNXkzkWjfjQn0CB6yzyS53vAnWeaRsObhc5eJmzcULx0/ QOUDIuRcpW1VcRYGJOnAgTxcrl0I1hHbNQwkchDordyyzSY+b3g5SDEvTEnxnlN2TCrJ/C 1tZ1fWdg6swwxEecyDhVTxbFwepdIfzumtIgIcHV1LszI/LJVjwHxqXFNHWlHQzFvdAJB4 wm/TKgDpA3O4UlhWgMm8kGILvvZVXvffPTDd7q9rZrQF5ZqdG/X/63D+h8MJog== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733780941; 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=IFVMyUHc1vQu1f29WShEPI1QukYsbyi4R7KVFVioWOQ=; b=XcGVCCDpCoM46FwdlFT8MHJhZaajxVRzssDgZabwh3lC8h74KLHN8xtNl7UbQkjzelqNIS DbrPPIrY0at1mn7eXijLc3+kMi108Nz/GXgr+k4JJlxjsWOU96PXeY5Qp1wUQ/uzRVK879 voDuOnX/nV7df5pKfIha4VdXsFZ/FDdbMJUeotfz9QOE9Z6/oDydYzNVTiDuLa37P7O3+M RpysCxJI0bBcMbLRukZDoMRCCJS0P3s+kl0/GB24IrIRgHLa4UdH2thJMKlwuExKwJHapf lGzsbPhTJMKahZAZ3VSVAKHRlmTXbJ+F/puZa/kcw0MV/IoPqE+j4BKNeAN1ww== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733780941; a=rsa-sha256; cv=none; b=hbC3zMZz9afJsYTLxbrbosUl9djFPaMT8o4Mh71VPgFsam5vprXA0FThM0BZMkUesA0Pkt 6gejtzyCiVaQUXUnaIKM87A15AxQsr9sV+IePm2XBa282JEP1fRNvVgDmECkGWoq/SNnOQ aZWlh1XI1rJu0Ewnmr55aOTuh9ruUGqrdoD4bXIy8KE24OQWv/5u85V1kd5icHUcDdttDy 7YHFBCLI8wmPRU3geYjyw/3snY7c6KmjgHzSojLc6k04baG9zW6SGfsPSegWiBhis2HXoU OPCYoeRo3I9jVGpoLYMgBgY0Wkn+bawXXKaQdzNCJDxBYOE8lIE4rufjJklv7A== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (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 did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4Y6b9902J8zvv5; Mon, 9 Dec 2024 21:49:01 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 4B9Ln0Hb033334; Mon, 9 Dec 2024 21:49:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9Ln0Cw033331; Mon, 9 Dec 2024 21:49:00 GMT (envelope-from git) Date: Mon, 9 Dec 2024 21:49:00 GMT Message-Id: <202412092149.4B9Ln0Cw033331@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Brooks Davis Subject: git: 6608a478cddb - stable/13 - depend-cleanup.sh: Extend clean_dep to support a custom regex 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: brooks X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 6608a478cddb98c1ad52ec0abae5240915fb2c57 Auto-Submitted: auto-generated The branch stable/13 has been updated by brooks: URL: https://cgit.FreeBSD.org/src/commit/?id=6608a478cddb98c1ad52ec0abae5240915fb2c57 commit 6608a478cddb98c1ad52ec0abae5240915fb2c57 Author: Jessica Clarke AuthorDate: 2024-09-10 17:54:44 +0000 Commit: Brooks Davis CommitDate: 2024-12-09 21:47:08 +0000 depend-cleanup.sh: Extend clean_dep to support a custom regex This will avoid having to duplicate the loop every time the default regex isn't good enough, and will be used by upcoming commits. (cherry picked from commit cc30f4ae6790cf4f19bc4787d7528dfea79ef27a) Pull Request: https://github.com/freebsd/freebsd-src/pull/1543 --- tools/build/depend-cleanup.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tools/build/depend-cleanup.sh b/tools/build/depend-cleanup.sh index 22baf65517fe..c12c8e203324 100755 --- a/tools/build/depend-cleanup.sh +++ b/tools/build/depend-cleanup.sh @@ -88,11 +88,12 @@ run() # $1 directory # $2 source filename w/o extension # $3 source extension +# $4 optional regex for egrep -w clean_dep() { for libcompat in "" $ALL_libcompats; do dirprfx=${libcompat:+obj-lib${libcompat}/} - if egrep -qw "$2\.$3" "$OBJTOP"/$dirprfx$1/.depend.$2.*o 2>/dev/null; then + if egrep -qw "${4:-$2\.$3}" "$OBJTOP"/$dirprfx$1/.depend.$2.*o 2>/dev/null; then echo "Removing stale ${libcompat:+lib${libcompat} }dependencies and objects for $2.$3" run rm -f \ "$OBJTOP"/$dirprfx$1/.depend.$2.* \