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

chore: test Rails 7.1 on JRuby 9.4.6.0 #532

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

joshuap
Copy link
Member

@joshuap joshuap commented Mar 21, 2024

This is currently failing. When I run bundle update, it fails when installing psych (which is required by rdoc):

Fetching psych 5.1.2 (was 4.0.3)
Installing psych 5.1.2 (was 4.0.3) with native extensions
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory:
/Users/josh/.asdf/installs/ruby/jruby-9.4.6.0/lib/ruby/gems/shared/gems/psych-5.1.2/ext/psych
/Users/josh/.asdf/installs/ruby/jruby-9.4.6.0/bin/jruby -I
/Users/josh/.asdf/installs/ruby/jruby-9.4.6.0/lib/ruby/stdlib extconf.rb
*** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of necessary
libraries and/or headers.  Check the mkmf.log file for more details.  You may
need configuration options.

Provided configuration options:
	--with-opt-dir
	--without-opt-dir
	--with-opt-include
	--without-opt-include=${opt-dir}/include
	--with-opt-lib
	--without-opt-lib=${opt-dir}/lib
	--with-make-prog
	--without-make-prog
	--srcdir=.
	--curdir
	--ruby=/Users/josh/.asdf/installs/ruby/jruby-9.4.6.0/bin/jruby
	--with-libyaml-source-dir
	--without-libyaml-source-dir
	--with-yaml-0.1-config
	--without-yaml-0.1-config
	--with-pkg-config
	--without-pkg-config
RuntimeError: The compiler failed to generate an executable file.
You have to install development tools first.

try_do at
/Users/josh/.asdf/installs/ruby/jruby-9.4.6.0/lib/ruby/stdlib/mkmf.rb:456
try_link0 at
/Users/josh/.asdf/installs/ruby/jruby-9.4.6.0/lib/ruby/stdlib/mkmf.rb:541
try_link at
/Users/josh/.asdf/installs/ruby/jruby-9.4.6.0/lib/ruby/stdlib/mkmf.rb:556
try_ldflags at
/Users/josh/.asdf/installs/ruby/jruby-9.4.6.0/lib/ruby/stdlib/mkmf.rb:657
pkg_config at
/Users/josh/.asdf/installs/ruby/jruby-9.4.6.0/lib/ruby/stdlib/mkmf.rb:1813
       <main> at extconf.rb:40

To see why this extension failed to compile, please check the mkmf.log which can
be found here:

/Users/josh/.asdf/installs/ruby/jruby-9.4.6.0/lib/ruby/gems/shared/extensions/universal-java-1.8/3.1.0/psych-5.1.2/mkmf.log

extconf failed, exit code 1

Gem files will remain installed in
/Users/josh/.asdf/installs/ruby/jruby-9.4.6.0/lib/ruby/gems/shared/gems/psych-5.1.2
for inspection.
Results logged to
/Users/josh/.asdf/installs/ruby/jruby-9.4.6.0/lib/ruby/gems/shared/extensions/universal-java-1.8/3.1.0/psych-5.1.2/gem_make.out

An error occurred while installing psych (5.1.2), and Bundler cannot
continue.
Make sure that `gem install psych -v '5.1.2' --source 'https://rubygems.org/'`
succeeds before bundling.

In Gemfile:
  rdoc was resolved to 6.6.3.1, which depends on
    psych

...which is odd, because running the suggested command to install psych by itself succeeds:

λ  honeybadger-ruby jruby-rails7.1 ✓ gem install psych -v '5.1.2' --source 'https://rubygems.org/'
  jar dependencies for psych-5.1.2-java.gemspec . . .
      org.snakeyaml:snakeyaml-engine:2.7:compile
Successfully installed psych-5.1.2-java
1 gem installed

After we get bundle install to work, we then need to install the Rails 7.1 gemfile with bundle exec appraisal rails7.1 bundle exec install.

@joshuap
Copy link
Member Author

joshuap commented Mar 21, 2024

cc @headius in case this is a quick/known issue.

@joshuap joshuap changed the title Test Rails 7.1 on JRuby 9.4.6.0 chore: test Rails 7.1 on JRuby 9.4.6.0 Mar 21, 2024
@headius
Copy link

headius commented Mar 26, 2024

This seems like it's trying to install the native extension psych rather than the JRuby version that has no native code. I'm not sure why this would happen unless a version of psych was released without the JRuby version.

FWIW there are some in-progress issues with JRuby and Rails 7.1 but I'm actively working on resolving them this week.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants