diff options
| author | Artem Bunichev <tembun@bk.ru> | 2026-02-19 19:09:48 +0000 |
|---|---|---|
| committer | Mark Johnston <markj@FreeBSD.org> | 2026-02-19 19:09:56 +0000 |
| commit | c8191c3d613928d8bd6060aa2f7da349b4090cc1 (patch) | |
| tree | cecaee4b5bd4515e94b020cbfc99c51969be0a6b | |
| parent | 3a0c63a7e0e7f8bd43b0d6b97a627198297e3bdb (diff) | |
OptionalObsoleteFiles: Don't mark /usr/lib/debug/boot directory obsolete
The intent of the currect code is to ignore anything under
/usr/lib/debug/boot/*. But we also should make sure that
/usr/lib/debug/boot directory is also ignored and is not marked
obsolete. If we don't do that, `make DBATCH_DELETE_OLD_FILES
delete-old` will try to rmdir(1) this directory, which will cause an
error, since /usr/lib/debug/boot may have nested directories like
kernel/ and modules/.
Reviewed by: markj
MFC after: 2 weeks
Differential Revision: https://reviews.freebsd.org/D55077
| -rw-r--r-- | tools/build/mk/OptionalObsoleteFiles.inc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/build/mk/OptionalObsoleteFiles.inc b/tools/build/mk/OptionalObsoleteFiles.inc index a30ede4c1866..81379ea452bb 100644 --- a/tools/build/mk/OptionalObsoleteFiles.inc +++ b/tools/build/mk/OptionalObsoleteFiles.inc @@ -1443,8 +1443,8 @@ OLD_DIRS+=usr/include/fs/cuse .if ${MK_DEBUG_FILES} == no .if exists(${DESTDIR}/usr/lib/debug) -DEBUG_DIRS!=find ${DESTDIR}/usr/lib/debug -mindepth 1 \ - -type d \! -path "${DESTDIR}/usr/lib/debug/boot/*" \ +DEBUG_DIRS!=find -E ${DESTDIR}/usr/lib/debug -mindepth 1 \ + -type d \! -regex "${DESTDIR}/usr/lib/debug/boot(/.*)?" \ | sed -e 's,^${DESTDIR}/,,'; echo DEBUG_FILES!=find ${DESTDIR}/usr/lib/debug \ \! -type d \! -path "${DESTDIR}/usr/lib/debug/boot/*" \! -name "lib*.so*" \ |
