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
F97562379: D37111.diff
Mon, Sep 30, 2:15 AM
F97550320: D37111.diff
Mon, Sep 30, 12:50 AM
F97546266: D37111.diff
Mon, Sep 30, 12:24 AM
F97527430: D37111.id112183.diff
Sun, Sep 29, 9:58 PM
F97479296: D37111.diff
Sun, Sep 29, 2:55 PM
Unknown Object (File)
Sat, Sep 28, 9:25 PM
Unknown Object (File)
Sat, Sep 28, 9:25 PM
Unknown Object (File)
Sat, Sep 28, 3:03 PM
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

Lint
Lint Skipped
Unit
Tests Skipped

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