Skip to content

fatal error: ruby/io.h: No such file or directory #8

Description

@flaccid

From execution of make in https://github.com/Lytro/chef_ruby/blob/master/recipes/default.rb#L17

...
04:33:11: make[2]: Entering directory/var/cache/rightscale/chef/ruby-1.9.3-p194/ext/openssl'
04:33:11: gcc -I. -I. -I/usr/lib/ruby/1.8/x86_64-linux -I. -DRUBY_EXTCONF_H="extconf.h" -D_FORTIFY_SOURCE=2 -D_FORTIFY_SOURCE=2 -fPIC -fno-strict-aliasing -g -g -O2 -fPIC -c ossl_ssl_session.c
04:33:11: In file included from ossl_ssl_session.c:5:0:
ossl.h:32:21: fatal error: ruby/io.h: No such file or directory
04:33:11: compilation terminated.
04:33:11: make[2]: *** [ossl_ssl_session.o] Error 1
04:33:11: make[2]: Leaving directory /var/cache/rightscale/chef/ruby-1.9.3-p194/ext/openssl' 04:33:11: make[1]: *** [ext/openssl/all] Error 2 make: *** [build-ext] Error 2 04:33:11: make[1]: Leaving directory/var/cache/rightscale/chef/ruby-1.9.3-p194'
04:33:11: Script duration: 53.677533
*ERROR> 04:33:11: bash[unpack ruby-1.9.3-p194.tar.bz2 and build](chef_ruby::default line 17) has had an error

*ERROR> 04:33:11: bash[unpack ruby-1.9.3-p194.tar.bz2 and build](/var/cache/rightscale/cookbooks/default/b3974743a4af3caaea749ca758add829/cookbooks/chef_ruby/recipes/default.rb:17:in from_file') had an error: bash[unpack ruby-1.9.3-p194.tar.bz2 and build](chef_ruby::default line 17) had an error: RightScale::Exceptions::Exec: ""bash" "/tmp/chef-script20130916-1423-fjqvv1-0"" exited with 2, expected 0.

This comes up on Google quite a bit, but I am not sure what the right solution actually is. But, I am pretty sure it would be this as I tested it:

sudo apt-get install libssl-dev cd ~/.rvm/src/ruby-1.8.7/ext/openssl ruby extconf.rb make && make install

From http://cjohansen.no/en/ruby/ruby_version_manager_ubuntu_and_openssl

I'll submit a pull request.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions