diff options
author | jsm28 <jsm28@138bc75d-0d04-0410-961f-82ee72b054a4> | 2011-05-19 16:25:12 +0000 |
---|---|---|
committer | jsm28 <jsm28@138bc75d-0d04-0410-961f-82ee72b054a4> | 2011-05-19 16:25:12 +0000 |
commit | 11091b4d06907a117524c3ac2b2a221d18cbb8dc (patch) | |
tree | d058c00dc1d7bc91f5480576092941a860ad9b64 /gcc/tlink.c | |
parent | c2b8897192542e99d6a98a46926f143fc2dd7bae (diff) | |
download | gcc-11091b4d06907a117524c3ac2b2a221d18cbb8dc.tar.gz |
* collect2.c: Include diagnostic.h.
(fatal_perror, fatal, error, fancy_abort): Remove.
(main): Set progname. Call xmalloc_set_program_name and
diagnostic_initialize.
(maybe_run_lto_and_relink, main, collect_execute, scan_prog_file,
scan_libraries, resolve_lib_name): Call fatal_error instead of
fatal and fatal_perror.
* collect2.h (error, fatal, fatal_perror): Don't declare.
* tlink.c: Include diagnostic-core.h.
(recompile_files): Call fatal_error instead of fatal_perror.
* Makefile.in (COLLECT2_OBJS): Include diagnostic.o,
pretty-print.o and input.o.
(collect2.o, tlink.o): Update dependencies.
testsuite:
* lib/prune.exe (prune_gcc_output): Expect "error:" in collect2
output.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@173915 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/tlink.c')
-rw-r--r-- | gcc/tlink.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/gcc/tlink.c b/gcc/tlink.c index 883aa0f0281..f0540478e72 100644 --- a/gcc/tlink.c +++ b/gcc/tlink.c @@ -2,7 +2,7 @@ them. Copyright (C) 1995, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2007, 2008, - 2009, 2010 Free Software Foundation, Inc. + 2009, 2010, 2011 Free Software Foundation, Inc. Contributed by Jason Merrill (jason@cygnus.com). This file is part of GCC. @@ -31,6 +31,7 @@ along with GCC; see the file COPYING3. If not see #include "demangle.h" #include "collect2.h" #include "filenames.h" +#include "diagnostic-core.h" /* TARGET_64BIT may be defined to use driver specific functionality. */ #undef TARGET_64BIT @@ -477,9 +478,9 @@ recompile_files (void) the new file name already exists. Therefore, we explicitly remove the old file first. */ if (remove (f->key) == -1) - fatal_perror ("removing .rpo file"); + fatal_error ("removing .rpo file: %m"); if (rename (outname, f->key) == -1) - fatal_perror ("renaming .rpo file"); + fatal_error ("renaming .rpo file: %m"); if (!f->args) { |