Message ID | 5659D60E.3080406@mentor.com |
---|---|
State | New |
Headers | show |
> > 2015-11-28 Tom de Vries <tom@codesourcery.com> > > * lto-wrapper.c (run_gcc): Handle -flinker-output argument. Thanks, this looks fine to me. THe way options are handled in lto-wrapper seems like a gross hack. Hopefully we will manage to clean this up eventually. What happens when I call one of input objects -fresolution=.o? Honza > > --- > gcc/lto-wrapper.c | 5 ++++- > 1 file changed, 4 insertions(+), 1 deletion(-) > > diff --git a/gcc/lto-wrapper.c b/gcc/lto-wrapper.c > index b9ac535..e4772d1 100644 > --- a/gcc/lto-wrapper.c > +++ b/gcc/lto-wrapper.c > @@ -1096,7 +1096,10 @@ run_gcc (unsigned argc, char *argv[]) > if (have_offload && !have_lto) > { > for (i = 1; i < argc; ++i) > - if (strncmp (argv[i], "-fresolution=", sizeof ("-fresolution=") - 1)) > + if (strncmp (argv[i], "-fresolution=", > + sizeof ("-fresolution=") - 1) != 0 > + && strncmp (argv[i], "-flinker-output=", > + sizeof ("-flinker-output=") - 1) != 0) > { > char *out_file; > /* Can be ".o" or ".so". */
Handle flinker-output in lto-wrapper 2015-11-28 Tom de Vries <tom@codesourcery.com> * lto-wrapper.c (run_gcc): Handle -flinker-output argument. --- gcc/lto-wrapper.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/gcc/lto-wrapper.c b/gcc/lto-wrapper.c index b9ac535..e4772d1 100644 --- a/gcc/lto-wrapper.c +++ b/gcc/lto-wrapper.c @@ -1096,7 +1096,10 @@ run_gcc (unsigned argc, char *argv[]) if (have_offload && !have_lto) { for (i = 1; i < argc; ++i) - if (strncmp (argv[i], "-fresolution=", sizeof ("-fresolution=") - 1)) + if (strncmp (argv[i], "-fresolution=", + sizeof ("-fresolution=") - 1) != 0 + && strncmp (argv[i], "-flinker-output=", + sizeof ("-flinker-output=") - 1) != 0) { char *out_file; /* Can be ".o" or ".so". */