public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug driver/57652] New: [4.7/4.8/4.9 Regression] collect2 does not clean up temporary files
@ 2013-06-19 13:47 dje at gcc dot gnu.org
  2013-06-19 13:50 ` [Bug driver/57652] " dje at gcc dot gnu.org
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: dje at gcc dot gnu.org @ 2013-06-19 13:47 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57652

            Bug ID: 57652
           Summary: [4.7/4.8/4.9 Regression] collect2 does not clean up
                    temporary files
           Product: gcc
           Version: 4.9.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: driver
          Assignee: unassigned at gcc dot gnu.org
          Reporter: dje at gcc dot gnu.org

The 2011-05-19 change to convert collect2 to use the common diagnostics
infrastructure broke collect2's handling of temporary files.  The original
error reporting routines reported the error message and, IMPORTANTLY, called
collect_exit(). collect_exit() removes temporary files through multiple
invocations of maybe_unlink().

The change to invoke fatal_error() in GCC's diagnostics.c directly terminates
without cleaning up the temporary files. This leaves at least 5 temporary files
in /tmp for each link step that results in an error message.  When using GNU
configure to probe system features, this creates numerous temporary files.

For example,

$ cat foo.c
int main () {}
$ gcc foo.c -lnonexistent
collect2: fatal error: library libnonexistent not found
compilation terminated.
$ ls /tmp/cc*
/tmp/cc0IcxVL.c   /tmp/ccKwuh03.x   /tmp/ccqMJsFn.le
/tmp/cc2taIMJ.ld  /tmp/cceKTq5n.o


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2021-08-30 22:20 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-06-19 13:47 [Bug driver/57652] New: [4.7/4.8/4.9 Regression] collect2 does not clean up temporary files dje at gcc dot gnu.org
2013-06-19 13:50 ` [Bug driver/57652] " dje at gcc dot gnu.org
2013-06-19 17:37 ` dje at gcc dot gnu.org
2013-06-22 18:47 ` dje at gcc dot gnu.org
2021-08-30 22:20 ` pinskia at gcc dot gnu.org
2021-08-30 22:20 ` pinskia at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).