Stop the linker's --dependency-file option from including temporary lto files.

PR 30568
  * ldfile.c (ldfile_try_open_bfd): Do not track lto generated temporary files.
This commit is contained in:
Nick Clifton 2023-06-28 13:49:43 +01:00
parent 8527c36694
commit b25c1a15cb
2 changed files with 10 additions and 1 deletions

View File

@ -1,3 +1,10 @@
2023-06-28 Nikita Popov <npopov@redhat.com>
Nick Clifton <nickc@redhat.com>
PR 30568
* ldfile.c (ldfile_try_open_bfd): Do not track lto generated
temporary files.
2023-06-21 Nick Clifton <nickc@redhat.com>
PR 29072

View File

@ -352,7 +352,9 @@ ldfile_try_open_bfd (const char *attempt,
return false;
}
track_dependency_files (attempt);
/* PR 30568: Do not track lto generated temporary object files. */
if (!entry->flags.lto_output)
track_dependency_files (attempt);
/* Linker needs to decompress sections. */
entry->the_bfd->flags |= BFD_DECOMPRESS;