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

Using erlport/ruby with Elixir v1.1.0 seems to have an issue, looking to understand the cause. #25

Open
stochastic-thread opened this issue Jun 16, 2015 · 1 comment

Comments

@stochastic-thread
Copy link

I made a repo demonstrating example usage with Python in Elixir here: (https://github.com/arthurcolle/elixir-snake)

When I redownload it, run mix deps.get, then iex -S mix, in the interpreter, running this should work:

just like how
iex(2)> {:ok, python} = :python.start() returns:
{:ok, #PID<0.90.0>}
the ruby version should also work, however running this:
iex(2)> {:ok, ruby} = :ruby.start()
{:ok, #PID<0.95.0>}
iex(3)> /Users/arthur/.rubies/ruby-2.2.2/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in require': cannot load such file -- erlport/cli (LoadError) from /Users/arthur/.rubies/ruby-2.2.2/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:inrequire'
from -e:1:in `

'

23:42:43.046 [error] GenServer #PID<0.95.0> terminating
Last message: {#Port<0.3940>, {:exit_status, 1}}
State: {:state, :infinity, 0, #Port<0.3940>, [], []}
** (stop) {:port_closed, {:code, 1}}

What exactly is the problem? Is there a gem that I need to download and install in order to make it work? I couldn't find this in the docs, but I'd appreciate any pointers. Thanks!

@fazibear
Copy link

You should build erlport with make to have ruby libs available. Also you can try erlport elixir wrapper: https://github.com/fazibear/export, it will build elport dependency for you.

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