aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorRichard Guenther <rguenther@suse.de>2010-05-07 22:13:14 +0000
committerRichard Biener <rguenth@gcc.gnu.org>2010-05-07 22:13:14 +0000
commit1522167d7cc65e0a62585ca25609daaafb4b6ca4 (patch)
treed1b90907224b3f04141c726bee17fca0e706fba1 /gcc
parentc082f9f3173cf8cfa7b57107ffb6c6999f4872dc (diff)
downloadgcc-1522167d7cc65e0a62585ca25609daaafb4b6ca4.zip
gcc-1522167d7cc65e0a62585ca25609daaafb4b6ca4.tar.gz
gcc-1522167d7cc65e0a62585ca25609daaafb4b6ca4.tar.bz2
lto-wrapper.c (run_gcc): Remove linker output from command line for LTRANS invocation.
2010-05-08 Richard Guenther <rguenther@suse.de> * lto-wrapper.c (run_gcc): Remove linker output from command line for LTRANS invocation. From-SVN: r159174
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/lto-wrapper.c13
2 files changed, 18 insertions, 0 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index d44a020..b3097a6 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+2010-05-08 Richard Guenther <rguenther@suse.de>
+
+ * lto-wrapper.c (run_gcc): Remove linker output from
+ command line for LTRANS invocation.
+
2010-05-07 Steven Bosscher <steven@gcc.gnu.org>
* config.gcc (i[34567]86-*-darwin*, x86_64-*-darwin*): Add
diff --git a/gcc/lto-wrapper.c b/gcc/lto-wrapper.c
index c9a37d9..3d88c8f 100644
--- a/gcc/lto-wrapper.c
+++ b/gcc/lto-wrapper.c
@@ -369,6 +369,7 @@ run_gcc (unsigned argc, char *argv[])
const char *collect_gcc_options, *collect_gcc;
struct obstack env_obstack;
bool seen_dumpbase = false;
+ bool seen_o = false;
char *dumpbase_suffix = NULL;
unsigned j;
@@ -422,6 +423,18 @@ run_gcc (unsigned argc, char *argv[])
dumpbase_suffix = option + 7 + j - i;
seen_dumpbase = false;
}
+ if (seen_o)
+ {
+ seen_o = false;
+ continue;
+ }
+
+ /* If we see -o, skip it and its argument. */
+ if (strncmp (option, "-o", 2) == 0)
+ {
+ seen_o = true;
+ continue;
+ }
/* LTRANS does not need -fwhopr. */
if (strncmp (option, "-fwhopr", 7) != 0)