Open catap opened 2 years ago
Can you clarify which artefacts you feel could/should be automatically cleaned up? In general, they're kept around so that a failed build can be restarted cleanly... although that sometimes doesn't really apply.
@thepowersgang I'm thinking about something like bootstrap-lean
from gcc build. The idea of bootstrap-lean
is remove all compiling objects after the step's artefact is ready. And when step's artefact doesn't required anymore => remove it also.
What I'm thinking.
output-1.54.0/rustc-build
can be removed after output-1.54.0/rustc
is ready (that reduces disk usage for more than 6Gb);output-1.54.0/cargo-build
can be removed after output-1.54.0/cargo
is ready (that reduces disk usage for more than 1Gb);output-1.54.0
can be removed after run_rustc/output-1.54.0/prefix/bin/cargo
and run_rustc/output-1.54.0/prefix-s/bin/rustc
is ready (that reduces disk usage for another ~0.8Gb)run_rustc/output-1.54.0/...
can be removed then not needed.To be honest (1) and (2) or just (3) makes huge win. Saves ~8Gb from ~14Gb of disk space usage.
What do you think?
A good idea, but that's not something I'd like to add to the default scripts as it'd make debugging much slower.
Right now build script never cleanup build artefacts from previous steps which increases disc usage.
Maybe it is possible to clean things up?