Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

binaries and plugins have executable stack by default #1701

Closed
dvzrv opened this issue Apr 10, 2020 · 3 comments
Closed

binaries and plugins have executable stack by default #1701

dvzrv opened this issue Apr 10, 2020 · 3 comments
Labels
Bug Report Item submitted using the Bug Report template Infrastructure Issues related to repository, CI/CD, installers, etc.
Milestone

Comments

@dvzrv
Copy link

dvzrv commented Apr 10, 2020

Describe the bug
When building 1.6.6 as a package for Arch Linux I realized that created executables and plugins have executable stack. This can be circumvented by adding -z,noexecstack to LDFLAGS.

Please let us know your surge version

  • Surge Version: 1.6.6
  • Plugin type n/a
  • Bits n/a

To Reproduce
Steps to reproduce the behavior:

  1. Build the headless binary or plugins
  2. Run namcap (Arch specific) on the resulting package or execstack on the elf files

Expected behavior
Executables and plugins don't have executable stack.

Desktop (please complete the following information):

  • OS: Arch Linux
  • Host n/a
  • Version n/a
@mkruselj mkruselj added the Infrastructure Issues related to repository, CI/CD, installers, etc. label Apr 11, 2020
@baconpaul
Copy link
Collaborator

So @dvzrv this is easy to add of course but a quick google leads me to understand that on some older architectures where this isn't hardware supported there can be some performance penalties. Am I mis-understanding? (that is entirely possible. It's been a decade or more since I worried about this sort of thing on unixes)

@baconpaul baconpaul added this to the 1.7 beta 1 milestone May 2, 2020
@dvzrv
Copy link
Author

dvzrv commented Jul 29, 2020

I think the performance penalty in relation to this is completely negliable.
I'm not even sure the processors in question would be able to reliably run surge (given that the total market share is probably around 0.01%).

@mkruselj mkruselj added the Bug Report Item submitted using the Bug Report template label Nov 9, 2020
baconpaul added a commit to baconpaul/surge that referenced this issue May 3, 2021
1. add the -z,noexecstack linker on gnu cc. Closes surge-synthesizer#1701
2. Add a surge-xt-standalone-run target for command line fun
@baconpaul
Copy link
Collaborator

paul@ubuntu:~/dev/music/surge-xt$ execstack  ~/.vst3/Surge.vst3/Contents/x86_64-linux/Surge.so 
X /home/paul/.vst3/Surge.vst3/Contents/x86_64-linux/Surge.so
paul@ubuntu:~/dev/music/surge-xt$ execstack ignore/avx/surge-xt_artefacts/Debug/VST3/Surge\ XT.vst3/Contents/x86_64-linux/Surge\ XT.so 
- ignore/avx/surge-xt_artefacts/Debug/VST3/Surge XT.vst3/Contents/x86_64-linux/Surge XT.so

next merge accomplishes that difference

baconpaul added a commit that referenced this issue May 3, 2021
1. add the -z,noexecstack linker on gnu cc. Closes #1701
2. Add a surge-xt-standalone-run target for command line fun
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Report Item submitted using the Bug Report template Infrastructure Issues related to repository, CI/CD, installers, etc.
Projects
None yet
Development

No branches or pull requests

3 participants