Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,14 @@ diff --git a/tasks/bin/cross-ruby.rake b/tasks/bin/cross-ruby.rake
index 8317a2a3..8ed21718 100644
--- a/tasks/bin/cross-ruby.rake
+++ b/tasks/bin/cross-ruby.rake
@@ -116,11 +116,31 @@
@@ -116,11 +116,32 @@
"--host=#{mingw_host}",
"--target=#{mingw_target}",
"--build=#{RUBY_BUILD}",
- '--enable-shared',
+ '--enable-install-static-library',
+ '--disable-jit-support',
+ '--disable-rpath',
+ 'ac_cv_lib_z_uncompress=no',
+ 'ac_cv_lib_crypt_crypt=no',
+ 'ac_cv_func_crypt_r=no',
Expand Down
11 changes: 11 additions & 0 deletions test/rcd_test/test/test_basic.rb
Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,15 @@ def test_largefile_op_removed_from_musl
is_linux = RUBY_PLATFORM.include?("linux")
assert_equal(is_linux, RcdTest.largefile_op_removed_from_musl)
end

def test_disabled_rpath
skip("jruby uses jar files without rpath") if RUBY_ENGINE == "jruby"

cext_fname = $LOADED_FEATURES.grep(/rcd_test_ext/).first
refute_nil(cext_fname, "the C-ext should be loaded")
cext_text = File.binread(cext_fname)
assert_match(/Init_rcd_test_ext/, cext_text, "C-ext shoud contain the init function")
refute_match(/usr\/local/, cext_text, "there should be no rpath to /usr/local/rake-compiler/ruby/x86_64-unknown-linux-musl/ruby-3.4.5/lib or so")
refute_match(/home\//, cext_text, "there should be no path to /home/ or so")
end
end
Loading