Skip to content
This repository was archived by the owner on Nov 13, 2026. It is now read-only.

Set nostackexec and stack-protector options - #1107

Merged
janvorli merged 1 commit into
dotnet:masterfrom
jkotas:noexecstack
Apr 10, 2016
Merged

janvorli merged 1 commit into
dotnet:masterfrom
jkotas:noexecstack

Conversation

@jkotas

@jkotas jkotas commented Apr 10, 2016

Copy link
Copy Markdown
Member

No description provided.

@jkotas

jkotas commented Apr 10, 2016

Copy link
Copy Markdown
Member Author

CoreRT port of dotnet/coreclr#4257. Ported stack-protector compiler settings as well while I was on it.

@MichalStrehovsky

Copy link
Copy Markdown
Member

This page says it's preferred to add a line to the .S files instead of passing --noexecstack to the compiler for portability reasons. Just want to make sure that option was considered. LGTM otherwise.

@jkotas

jkotas commented Apr 10, 2016

Copy link
Copy Markdown
Member Author

Adding ifdefed code to every .s file as they are suggesting does not seem great for portability. It means that you have to fix a ton of places instead of just one when you need to change it for new target. And you have to be careful to add the cruft to every assembly file in your project. It is easy to miss one.

Searching for -Wa,--noexecstack on github shows that it is used by many projects. It should be portable enough.

cc @janvorli

@janvorli

Copy link
Copy Markdown
Member

LGTM

@janvorli
janvorli merged commit 6fdf563 into dotnet:master Apr 10, 2016
@jkotas
jkotas deleted the noexecstack branch April 16, 2016 00:27
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants