This adds a new job to the Package Kit, and an invocation in pkgman after changes are applied. The job takes a time_t before, and an int32 minToKeep, and (after confirmation) deletes all state directories which were last modified before that time, but also keeps at least the minimum specified. pkgman defaults to calling it with (now - 30 days, minimum 10). SoftwareUpdater does the same, but without bothering the user and just defaults to doing the cleanup. Change-Id: I15f5232b11daba5955e7fa07f696ad7785507931 Reviewed-on: https://review.haiku-os.org/c/haiku/+/10404 Reviewed-by: waddlesplash <[email protected]>