Linux + Clang + execstack
Magnus Ihse Bursie
magnus.ihse.bursie at oracle.com
Wed Sep 19 07:56:55 UTC 2018
On 2018-09-19 02:01, Martin Buchholz wrote:
> Unfortunately, my gmail marked Arthur's emails to this thread as spam,
> with ensuing confusion.
> I retargeted this fix to the new bug
> 8209817: stack is executable when building with Clang on Linux
> and it made it through the submit repo tests.
> Ready to submit this.
> On Thu, Sep 13, 2018 at 2:10 PM, Magnus Ihse Bursie
> <magnus.ihse.bursie at oracle.com> wrote:
>>> We're not entirely happy either.
>>> A much higher interface might look like
>>> TRY_ADD_LINKER_FLAGS -z noexecstack
>> Agreed. I'm working towards a solution like that.
>>> which would add -Wl,-z,noexecstack to LDFLAGS when appropriate
>>> .... hmmm ...
>>> I only just noticed that both gcc and clang accept simply
>>> $CC -z noexecstack
>>> (it's even documented!)
>>> Should we switch to that instead?
>> No, I think it's better to keep -Wl,-z for consistency for all linker flags.
>> Otherwise it just looks confusing.
>>>> Do you have a JBS issue?
>>> I have
>>> https://bugs.openjdk.java.net/browse/JDK-8205457 gcc and clang should
>>> use the same ld flags
>>> but the proposed patch only addresses part of that. I could create a
>>> sub-task (but I've never done that before) or a new bug or change the
>>> description of this bug. What do you think?
More information about the hotspot-dev