JRuby / Windows和(本地)扩展如何区分它们? [英] JRuby/Windows and (native) extensions how do I distinguish them?

查看:134
本文介绍了JRuby / Windows和(本地)扩展如何区分它们?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我尝试在JRuby中使用EventMachine等。我收到有关本机扩展的错误。我相信这是由于Java的限制。我认为我在Windows上的事实使问题更加复杂化。一些澄清将不胜感激。哪些扩展可以/不能用于JRuby?我怎么知道?谢谢。

解决方案

在jruby中使用原生扩展并不是一种简单的方法。本机扩展调用的是不能在java中实现的c代码,它不能在jruby中调用。除此之外,还有一些扩展可以看到jruby端口,例如您提到的EventMachine。



以及据我所知,唯一的方法就是看看是否可以使用gem / jruby的扩展是阅读文档,尝试它或阅读源文件

I've tried to use EventMachine etc., with JRuby. I get errors about native extensions. I believe this is due to Java limitations. I think the fact that I am on Windows further complicates the issue. Some clarification would be appreciated. What extensions can/can't be used with JRuby? How can I tell? Thanks.

解决方案

there is no really easy way to use native extensions in jruby. native extensions are calling c code that cant be called in jruby without implementing it in java. aside from that a few extensions are seeing jruby ports, for example EventMachine that you mentioned.

and as far as i know the only way to see if you can use a gem/extension with jruby is to read the docs, try it or read the source

这篇关于JRuby / Windows和(本地)扩展如何区分它们?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆