Commit 21b624f0 by Richard Biener Committed by Richard Biener

lto-plugin.c (onload): Fail to load if -fno-use-linker-plugin is set in COLLECT_GCC_OPTIONS.

2014-04-02  Richard Biener  <rguenther@suse.de>

	* lto-plugin.c (onload): Fail to load if -fno-use-linker-plugin
	is set in COLLECT_GCC_OPTIONS.

From-SVN: r209011
parent a1ce39be
2014-04-02 Richard Biener <rguenther@suse.de>
* lto-plugin.c (onload): Fail to load if -fno-use-linker-plugin
is set in COLLECT_GCC_OPTIONS.
2014-03-28 Richard Biener <rguenther@suse.de> 2014-03-28 Richard Biener <rguenther@suse.de>
* lto-plugin.c (process_symtab): Handle EINTR and short reads. * lto-plugin.c (process_symtab): Handle EINTR and short reads.
......
...@@ -1067,5 +1067,12 @@ onload (struct ld_plugin_tv *tv) ...@@ -1067,5 +1067,12 @@ onload (struct ld_plugin_tv *tv)
"could not register the all_symbols_read callback"); "could not register the all_symbols_read callback");
} }
/* Support -fno-use-linker-plugin by failing to load the plugin
for the case where it is auto-loaded by BFD. */
char *collect_gcc_options = getenv ("COLLECT_GCC_OPTIONS");
if (collect_gcc_options
&& strstr (collect_gcc_options, "'-fno-use-linker-plugin'"))
return LDPS_ERR;
return LDPS_OK; return LDPS_OK;
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment