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

Passenger fails to build native extensions on JRuby #145

Closed
hone opened this issue Sep 9, 2013 · 4 comments
Closed

Passenger fails to build native extensions on JRuby #145

hone opened this issue Sep 9, 2013 · 4 comments

Comments

@hone
Copy link
Member

hone commented Sep 9, 2013

There's an issue pushing Phusion Passenger 4.0.16 to Heroku.

Installing passenger (4.0.16)
Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.

/tmp/build_3cxwicvv98ei4/vendor/ruby-1.9.3-jruby-1.7.4/bin/jruby extconf.rb
Picked up JAVA_TOOL_OPTIONS: -Djava.rmi.server.useCodebaseOnly=true
FailoverSwitchPointInvalidator.java:34:in `<clinit>': java.lang.NoClassDefFoundError: java/lang/invoke/SwitchPoint
from OptoFactory.java:96:in `newGlobalInvalidator'
from Ruby.java:4668:in `<init>'
from Ruby.java:275:in `newInstance'
from Main.java:262:in `internalRun'
from Main.java:221:in `run'
from Main.java:201:in `main'


Gem files will remain installed in /tmp/build_3cxwicvv98ei4/vendor/bundle/jruby/1.9/gems/passenger-4.0.16 for inspection.
Results logged to /tmp/build_3cxwicvv98ei4/vendor/bundle/jruby/1.9/gems/passenger-4.0.16/helper-scripts/download_binaries/gem_make.out
An error occurred while installing passenger (4.0.16), and Bundler cannot
continue.
Make sure that `gem install passenger -v '4.0.16'` succeeds before bundling.
!
! Failed to install gems via Bundler.
!

! Push rejected, failed to compile Ruby/Rails app
@hone
Copy link
Member Author

hone commented Sep 9, 2013

I talked with @headius and turning off indy fixed the issue.

@rwilliams
Copy link

Maybe you could check the java runtime version and only enable indy if it's 1.8+ I'm trying to test it with my app but I can't seem to force my slug to use 1.8.

https://github.com/jruby/jruby/wiki/PerformanceTuning#enabling-invokedynamic

Edit: Also this fix will hurt performance for Puma/JRuby users. Maybe it requires a bit more investigation.

@hone
Copy link
Member Author

hone commented Sep 9, 2013

@rwilliams you can opt in by setting JRUBY_OPTS as a config var, but after talking with @headius, we should enable it by default only after 7u40. We're currently on 7u30 on cedar.

Edit: 7u40 is supposed to fix the remaining indy bugs. :)

@rwilliams
Copy link

@hone Makes sense. Thanks

@hone hone closed this as completed Sep 9, 2013
@hone hone reopened this Sep 9, 2013
@hone hone closed this as completed in 74f0b90 Sep 18, 2013
hone added a commit that referenced this issue Sep 18, 2013
hone added a commit that referenced this issue Oct 29, 2013
gbenedict pushed a commit to RedFunnel/heroku-buildpack-ruby that referenced this issue Jan 9, 2014
squeedee referenced this issue in cloudfoundry/ruby-buildpack Apr 10, 2014
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

No branches or pull requests

2 participants