Handle link_info.pie in ld plugin

* plugin.c (set_tv_header): Handle link_info.pie.
This commit is contained in:
H.J. Lu 2012-06-14 23:44:38 +00:00
parent 3771a44cf0
commit 6611f2e124
2 changed files with 7 additions and 1 deletions

View File

@ -1,3 +1,7 @@
2012-06-14 H.J. Lu <hongjiu.lu@intel.com>
* plugin.c (set_tv_header): Handle link_info.pie.
2012-06-11 Alan Modra <amodra@gmail.com>
PR ld/14215

View File

@ -697,7 +697,9 @@ set_tv_header (struct ld_plugin_tv *tv)
case LDPT_LINKER_OUTPUT:
TVU(val) = (link_info.relocatable
? LDPO_REL
: link_info.executable ? LDPO_EXEC : LDPO_DYN);
: (link_info.executable
? (link_info.pie ? LDPO_PIE : LDPO_EXEC)
: LDPO_DYN));
break;
case LDPT_OUTPUT_NAME:
TVU(string) = output_filename;