aports/community/ruby-ffi/musl-compat.patch
2023-09-25 09:18:46 +00:00

14 lines
625 B
Diff

Fix handling of ldscript.so files.
--- a/lib/ffi/dynamic_library.rb
+++ b/lib/ffi/dynamic_library.rb
@@ -74,7 +74,7 @@
# LoadError for C ext & JRuby, RuntimeError for TruffleRuby
rescue LoadError, RuntimeError => ex
- if ex.message =~ /(([^ \t()])+\.so([^ \t:()])*):([ \t])*(invalid ELF header|file too short|invalid file format)/
+ if ex.message =~ /(([^ \t()])+\.so([^ \t:()])*):([ \t])*(invalid ELF header|file too short|invalid file format|Exec format error)/
if File.binread($1) =~ /(?:GROUP|INPUT) *\( *([^ \)]+)/
return try_load($1, flags, errors)
end