Mac: set -obj_path_lto when building with LTO

This temporarily saves intermediate object files (other than cache hits
which are already persisted in the cache directory) so that `dsymutil`
can read the debug info out of them.

This change also adds an argument to to clean this
directory up after `dsymutil` has run. I'm not sure this is the best
way to do it, so very open to other suggestions.

Bug: 1324104
Change-Id: I001e19b9824ff8bf969c5b713a3e0dbed52e5df5
Reviewed-by: Nico Weber <>
Commit-Queue: Leonard Grey <>
Cr-Commit-Position: refs/heads/main@{#1004779}
GitOrigin-RevId: fb34ab468f55c8c383b31b341544627cb97efb25
1 file changed