Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
Signed-off-by: Jun Aruga <jaruga@redhat.com>
  • Loading branch information
junaruga committed Nov 21, 2019
1 parent 6d340bd commit 82511e3
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions test/fiddle/helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,16 @@
case RbConfig::SIZEOF['void*']
when 4
# 32-bit ruby
libdir = '/lib32' if File.directory? '/lib32'
libdir = '/lib/arm-linux-gnueabihf' if File.directory? '/lib/arm-linux-gnueabihf'
case RUBY_PLATFORM
when /armv.*-linux/
# In the ARM 32-bit libc package such as libc6:armhf libc6:armel,
# libc.so and libm.so are installed to /lib/arm-linux-gnu*.
# It's not installed to /lib32.
dirs = Dir.glob('/lib/arm-linux-gnu*')
libdir = dirs[0] if dirs && File.directory?(dirs[0])
else
libdir = '/lib32' if File.directory? '/lib32'
end
when 8
# 64-bit ruby
libdir = '/lib64' if File.directory? '/lib64'
Expand Down

0 comments on commit 82511e3

Please sign in to comment.