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

Missing Constants #2774

Closed
stakach opened this issue Nov 10, 2013 · 5 comments
Closed

Missing Constants #2774

stakach opened this issue Nov 10, 2013 · 5 comments

Comments

@stakach
Copy link

stakach commented Nov 10, 2013

MRI Specifies:
Socket::Constants::INET_ADDRSTRLEN
Socket::Constants::INET6_ADDRSTRLEN

They should be
INET_ADDRSTRLEN = 16
INET6_ADDRSTRLEN = 46

@dbussink
Copy link
Contributor

These are available here for me. What exact platform are you on?

@stakach
Copy link
Author

stakach commented Nov 11, 2013

This is the Travis result: https://travis-ci.org/cotag/libuv/builds/13758324
The code that was causing the issue: https://github.com/cotag/libuv/blob/4e4f44b37a9fa615306838b2ec5cfae67fac73c4/lib/libuv/mixins/net.rb#L29

I then tested on Rubinius 2.0 (installed approximately around the time of 2.0 release) and jRuby 1.7.4 on OSX in IRB to confirm.

irb
require 'socket'
::Socket::Constants::INET_ADDRSTRLEN
-> NameError: uninitialized constant Socket::Constants::INET_ADDRSTRLEN

Works in MRI ruby-2.0.0-p247 for me.

@dbussink
Copy link
Contributor

That's very strange, I just ran this on latest master on OS X:

require 'socket'
::Socket::Constants::INET_ADDRSTRLEN
# => 16

@stakach
Copy link
Author

stakach commented Nov 11, 2013

I assume that means it is a matter of time before the problem rectifies itself... Next Rubinius weekly for instance?
I'd test on head except rvm is giving me issue.

Stephens-MacBook-Pro:uv-rays stakach$ sudo rvm install rbx-head
Password:
Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr --with-gxx-include-dir=/usr/include/c++/4.2.1
rbx-head installing #dependencies
Installing requirements for osx, might require sudo password.
Certificates in '/usr/local/etc/openssl/cert.pem' already are up to date.
Requirements installation successful.
Cleaning git repo..
Fetching from origin
Pulling from origin master...
Copying from repo to source...
rbx-head - #configuring.................
Error running 'env /Users/stakach/.rvm/wrappers/ruby-2.0.0-p247/ruby ./configure --prefix=/Users/stakach/.rvm/rubies/rbx-head --with-opt-dir=/usr/local/opt/libyaml --with-opt-dir=/usr/local/opt/readline --with-opt-dir=/usr/local/opt/libksba --with-opt-dir=/usr/local/opt/openssl',
please read /Users/stakach/.rvm/log/rbx-head/1384211109_configure.log
There has been an error while running 'configure'.
Halting the installation.

@stakach
Copy link
Author

stakach commented Nov 12, 2013

You are correct. Works in latest head.

rubinius-2.1.1.n316 :002 > ::Socket::Constants::INET_ADDRSTRLEN
=> 16

@stakach stakach closed this as completed Nov 12, 2013
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