features = 0;
if (info->ibt)
features = GNU_PROPERTY_X86_FEATURE_1_IBT;
+ if (info->shstk)
+ features |= GNU_PROPERTY_X86_FEATURE_1_SHSTK;
number = aprop->u.number;
- /* Add GNU_PROPERTY_X86_FEATURE_1_IBT. */
+ /* Add GNU_PROPERTY_X86_FEATURE_1_IBT and
+ GNU_PROPERTY_X86_FEATURE_1_SHSTK. */
aprop->u.number = (number & bprop->u.number) | features;
updated = number != (unsigned int) aprop->u.number;
/* Remove the property if all feature bits are cleared. */
features = 0;
if (info->ibt)
features = GNU_PROPERTY_X86_FEATURE_1_IBT;
+ if (info->shstk)
+ features |= GNU_PROPERTY_X86_FEATURE_1_SHSTK;
if (features)
{
- /* Add GNU_PROPERTY_X86_FEATURE_1_IBT. */
+ /* Add GNU_PROPERTY_X86_FEATURE_1_IBT and
+ GNU_PROPERTY_X86_FEATURE_1_SHSTK. */
if (aprop != NULL)
{
number = aprop->u.number;
features = 0;
if (info->ibt)
features = GNU_PROPERTY_X86_FEATURE_1_IBT;
+ if (info->shstk)
+ features |= GNU_PROPERTY_X86_FEATURE_1_SHSTK;
if (features)
{
- /* Turn on GNU_PROPERTY_X86_FEATURE_1_IBT. */
+ /* Turn on GNU_PROPERTY_X86_FEATURE_1_IBT and
+ GNU_PROPERTY_X86_FEATURE_1_SHSTK. */
bfd *ebfd = NULL;
elf_property *prop;
prop = _bfd_elf_get_property (pbfd,
GNU_PROPERTY_X86_FEATURE_1_AND,
4);
- /* Add GNU_PROPERTY_X86_FEATURE_1_IBT. */
+ /* Add GNU_PROPERTY_X86_FEATURE_1_IBT and
+ GNU_PROPERTY_X86_FEATURE_1_SHSTK. */
prop->u.number |= features;
prop->pr_kind = property_number;
break;