diff --git a/ruby-2.8.0-Annotate-execstack.patch b/ruby-2.8.0-Annotate-execstack.patch new file mode 100644 index 0000000..404d8fc --- /dev/null +++ b/ruby-2.8.0-Annotate-execstack.patch @@ -0,0 +1,12 @@ +diff --git a/coroutine/arm32/Context.S b/coroutine/arm32/Context.S +index b66db29622..596284b5cf 100644 +--- a/coroutine/arm32/Context.S ++++ b/coroutine/arm32/Context.S +@@ -24,3 +24,7 @@ coroutine_transfer: + + # Restore callee state (8 registers program counter) + pop {r4-r11,pc} ++ ++#if defined(__linux__) && defined(__ELF__) ++.section .note.GNU-stack,"",%progbits ++#endif diff --git a/ruby.spec b/ruby.spec index 0819949..5b5f18b 100644 --- a/ruby.spec +++ b/ruby.spec @@ -140,6 +140,9 @@ Patch9: ruby-2.3.1-Rely-on-ldd-to-detect-glibc.patch # Revert commit which breaks bundled net-http-persistent version check. # https://github.com/drbrain/net-http-persistent/pull/109 Patch10: ruby-2.7.0-Remove-RubyGems-dependency.patch +# Fix fortifications on armv7hl. +# https://bugs.ruby-lang.org/issues/16762 +Patch11: ruby-2.8.0-Annotate-execstack.patch Requires: %{name}-libs%{?_isa} = %{version}-%{release} Suggests: rubypick @@ -568,6 +571,7 @@ rm -rf ext/fiddle/libffi* %patch6 -p1 %patch9 -p1 %patch10 -p1 +%patch11 -p1 # Provide an example of usage of the tapset: cp -a %{SOURCE3} .