Commit ea913779 by H.J. Lu Committed by H.J. Lu

Set flag_pic to flag_pie for PIE in LTO

Since PIE implies PIC, we should set flag_pic to flag_pie for PIE in
LTO.

	PR lto/70258
	* lto-lang.c (lto_post_options): Set flag_pic to flag_pie for
	PIE.

From-SVN: r234284
parent 0c8b64cb
2016-03-17 H.J. Lu <hongjiu.lu@intel.com>
PR lto/70258
* lto-lang.c (lto_post_options): Set flag_pic to flag_pie for
PIE.
2016-03-08 Jakub Jelinek <jakub@redhat.com>
* lto-symtab.h (lto_symtab_prevail_decl): Fix spelling
......
......@@ -836,7 +836,7 @@ lto_post_options (const char **pfilename ATTRIBUTE_UNUSED)
/* If -fPIC or -fPIE was used at compile time, be sure that
flag_pie is 2. */
flag_pie = MAX (flag_pie, flag_pic);
flag_pic = 0;
flag_pic = flag_pie;
break;
case LTO_LINKER_OUTPUT_EXEC: /* Normal executable */
......
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