Page MenuHomeFreeBSD

Use `rm -fv` for BATCH_DELETE_OLD_FILES
ClosedPublic

Authored by emaste on Oct 24 2022, 6:10 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mar 22 2024, 8:38 PM
Unknown Object (File)
Mar 22 2024, 11:49 AM
Unknown Object (File)
Mar 22 2024, 11:49 AM
Unknown Object (File)
Mar 22 2024, 11:03 AM
Unknown Object (File)
Mar 18 2024, 4:11 PM
Unknown Object (File)
Mar 18 2024, 5:44 AM
Unknown Object (File)
Feb 10 2024, 7:38 PM
Unknown Object (File)
Jan 18 2024, 4:05 AM
Subscribers
None

Details

Summary

It's possible to have files with odd permissions in the tmproot (or sysroot), causing rm to prompt for each one. Add -f to forcibly delete these.

Example:

override r--r--r-- emaste/wheel uarch for /usr/obj/usr/home/emaste/src/freebsd-git/wipbsd/amd64.amd64/sysroot/usr/include/c++/v1/__functional_base? y
override r--r--r-- emaste/wheel uarch for /usr/obj/usr/home/emaste/src/freebsd-git/wipbsd/amd64.amd64/sysroot/usr/include/c++/v1/__libcpp_version? y
override r--r--r-- emaste/wheel uarch for /usr/obj/usr/home/emaste/src/freebsd-git/wipbsd/amd64.amd64/sysroot/usr/include/c++/v1/__nullptr? y
override r--r--r-- emaste/wheel uarch for /usr/obj/usr/home/emaste/src/freebsd-git/wipbsd/amd64.amd64/sysroot/usr/include/c++/v1/__string? y

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

emaste created this revision.

Seems generally reasonable. Do we need to check afterwards to warn if they were not deleted?

This revision is now accepted and ready to land.Oct 25 2022, 2:54 AM

Seems generally reasonable. Do we need to check afterwards to warn if they were not deleted?

The build will exit if rm fails, e.g.

>>> Deleting stale files in build tree...
rm: /usr/obj/usr/home/emaste/src/freebsd-git/wipbsd/amd64.amd64/sysroot/usr/tests/usr.sbin/pw/pw_lock: Operation not permitted