rtomayko / posix-spawn

Ruby process spawning library
Other
519 stars 52 forks source link

[JRuby] ERROR: Failed to build gem native extension. #28

Closed skull-squadron closed 9 years ago

skull-squadron commented 12 years ago

Tried with gcc-4.2 and llvm.

Building native extensions.  This could take a while...
ERROR:  Error installing posix-spawn:
    ERROR: Failed to build gem native extension.

        /path/to/.rvm/rubies/jruby-1.6.7/bin/jruby extconf.rb
WARNING: JRuby does not support native extensions or the `mkmf' library very well.
Check http://kenai.com/projects/jruby/pages/Home for alternatives.
creating Makefile

Gem files will remain installed in /path/to/.rvm/gems/jruby-1.6.7@global/gems/posix-spawn-0.3.6 for inspection.
Results logged to /path/to/.rvm/gems/jruby-1.6.7@global/gems/posix-spawn-0.3.6/ext/gem_make.out
ezkl commented 11 years ago

I realize this is a 7 month old issue, but Google brought me here, so I'll answer it.

This isn't a posix-spawn bug, this is normal behavior for JRuby. To install libraries with C extensions in JRuby, you'll need to set jruby to load w/ the property -Xcext.enabled=true

The easiest way to do this? export JRUBY_OPTS="-Xcext.enabled=true"

sambeau commented 11 years ago

I'm getting this error and I'm not using JRuby, I've got ruby1.9.1 (on ubuntu)

jontonsoup commented 11 years ago

:+1:

rtomayko commented 9 years ago

Closing as we don't have plans to support JRuby in posix-spawn.