Rubygems "ERROR: Failed to build gem native extension." when installing Hobo gem

245 views
Skip to first unread message

Quiliro Ordóñez

unread,
May 3, 2012, 12:27:52 PM5/3/12
to Hobo Users
Hi.

I have installed Rubygems 1.9.2 from the apt repos. Then I updated
Rubygems and tryed to install Hobo 1.3. I get "ERROR: Failed to build
gem native extension.":

quiliro@trisquel:~$ sudo aptitude show ruby1.9.1
Paquete: ruby1.9.1
Estado: sin instalar
Instalado autom�ticamente: no
Versi�n: 1.9.2.290-2
Prioridad: opcional
Secci�n: universe/ruby
Desarrollador: Ubuntu Developers <ubuntu-dev...@lists.ubuntu.com>
Tama�o sin comprimir: 918 k
Depende de: libruby1.9.1 (= 1.9.2.290-2), libc6 (>= 2.0)
Sugiere: ruby1.9.1-examples, ri1.9.1, graphviz, ruby1.9.1-dev
Tiene conflictos con: irb1.9.1 (< 1.9.1.378-2~), rdoc1.9.1 (<
1.9.1.378-2~), ri (<= 4.5), ri1.9.1 (< 1.9.2.180-3~), ruby (<= 4.5),
rubygems1.9.1
Reemplaza: irb1.9.1, rdoc1.9.1, rubygems1.9.1
Proporciona: irb1.9.1, rdoc1.9.1, ruby-interpreter, ruby1.9.2, rubygems1.9.1
Descripci�n: Interpreter of object-oriented scripting language Ruby 1.9.2
Ruby es un lenguaje interpretado de guiones, que permite programar con
orientaci�n a objetos de manera r�pida y sencilla. Tiene muchas
funcionalidades para procesar archivos de
texto y realizar tareas de administraci�n de sistemas (como perl). Es
simple, directo y extensible.

In the name of this package, `1.9.1' indicates the Ruby library
compatibility version. This package currently provides the `1.9.2'
branch of Ruby, which is compatible with the
`1.9.1' branch.
P�gina de inicio: http://www.ruby-lang.org/

quiliro@trisquel:~$ sudo aptitude install ruby1.9.1
Se instalar�n los siguiente paquetes NUEVOS:
libruby1.9.1{a} libyaml-0-2{a} ruby1.9.1
0 paquetes actualizados, 3 nuevos instalados, 0 para eliminar y 7 sin
actualizar.
Necesito descargar 0 B/4022 kB de archivos. Despu�s de desempaquetar se
usar�n 15,7 MB.
�Quiere continuar? [Y/n/?]
Seleccionando el paquete libyaml-0-2 previamente no seleccionado.
(Leyendo la base de datos ... 210885 ficheros o directorios instalados
actualmente.)
Desempaquetando libyaml-0-2 (de .../libyaml-0-2_0.1.4-1_i386.deb) ...
Seleccionando el paquete libruby1.9.1 previamente no seleccionado.
Desempaquetando libruby1.9.1 (de .../libruby1.9.1_1.9.2.290-2_i386.deb) ...
Seleccionando el paquete ruby1.9.1 previamente no seleccionado.
Desempaquetando ruby1.9.1 (de .../ruby1.9.1_1.9.2.290-2_i386.deb) ...
Procesando disparadores para man-db ...
Configurando libyaml-0-2 (0.1.4-1) ...
Configurando libruby1.9.1 (1.9.2.290-2) ...
Configurando ruby1.9.1 (1.9.2.290-2) ...
update-alternatives: utilizando /usr/bin/gem1.9.1 para proveer
/usr/bin/gem (gem) en modo autom�tico.
update-alternatives: utilizando /usr/bin/ruby1.9.1 para proveer
/usr/bin/ruby (ruby) en modo autom�tico.
Procesando disparadores para libc-bin ...
ldconfig deferred processing now taking place

quiliro@trisquel:~$ sudo gem update
Updating installed gems
Nothing to update
quiliro@trisquel:~$ sudo gem install hobo
Building native extensions. This could take a while...
ERROR: Error installing hobo:
ERROR: Failed to build gem native extension.

/usr/bin/ruby1.9.1 extconf.rb
<internal:lib/rubygems/custom_require>:29:in `require': no such file to
load -- mkmf (LoadError)
from <internal:lib/rubygems/custom_require>:29:in `require'
from extconf.rb:1:in `<main>'


Gem files will remain installed in /var/lib/gems/1.9.1/gems/json-1.7.0
for inspection.
Results logged to
/var/lib/gems/1.9.1/gems/json-1.7.0/ext/json/ext/parser/gem_make.out
quiliro@trisquel:~$

--
Saludos libres,

Quiliro Ord��ez
(593)2-253 5534
(593)2-340 1517
(593)9-675 9641

Bryan Larsen

unread,
May 3, 2012, 12:44:07 PM5/3/12
to hobo...@googlegroups.com
two problems:

1) rubygems & dpkg are incompatible at the design level. In my
opinion, it's the design of rubygems that's broken, but we have to
live with it. So the quick answer is "never install rubygems via
dpkg". There are several solutions, but the one I recommend for
development boxes is to install rvm (https://rvm.io/) and then install
ruby through that. It is possible to get Hobo to work using the
Ubuntu supplied rubygems, but you'll probably run into problems later.

2) you're missing some build dependencies. In this case you're
missing ruby1.9.1.dev. You could apt-get install that, but instead I
recommend installing ruby through RVM. "rvm notes" will tell you
exactly what you need to install for your OS.

Bryan

On Thu, May 3, 2012 at 12:27 PM, Quiliro Ordóñez
<qui...@congresolibre.org> wrote:
> Hi.
>
> I have installed Rubygems 1.9.2 from the apt repos. Then I  updated Rubygems
> and tryed to install Hobo 1.3. I get "ERROR: Failed to build gem native
> extension.":
>
> quiliro@trisquel:~$ sudo aptitude show ruby1.9.1
> Paquete: ruby1.9.1
> Estado: sin instalar
> Instalado automáticamente: no
> Versión: 1.9.2.290-2
> Prioridad: opcional
> Sección: universe/ruby
> Desarrollador: Ubuntu Developers <ubuntu-dev...@lists.ubuntu.com>
> Tamaño sin comprimir: 918 k
> Depende de: libruby1.9.1 (= 1.9.2.290-2), libc6 (>= 2.0)
> Sugiere: ruby1.9.1-examples, ri1.9.1, graphviz, ruby1.9.1-dev
> Tiene conflictos con: irb1.9.1 (< 1.9.1.378-2~), rdoc1.9.1 (< 1.9.1.378-2~),
> ri (<= 4.5), ri1.9.1 (< 1.9.2.180-3~), ruby (<= 4.5), rubygems1.9.1
> Reemplaza: irb1.9.1, rdoc1.9.1, rubygems1.9.1
> Proporciona: irb1.9.1, rdoc1.9.1, ruby-interpreter, ruby1.9.2, rubygems1.9.1
> Descripción: Interpreter of object-oriented scripting language Ruby 1.9.2
>  Ruby es un lenguaje interpretado de guiones, que permite programar con
> orientación a objetos de manera rápida y sencilla. Tiene muchas
> funcionalidades para procesar archivos de
>  texto y realizar tareas de administración de sistemas (como perl). Es
> simple, directo y extensible.
>
>  In the name of this package, `1.9.1' indicates the Ruby library
> compatibility version. This package currently provides the `1.9.2' branch of
> Ruby, which is compatible with the
>  `1.9.1' branch.
> Página de inicio: http://www.ruby-lang.org/
>
> quiliro@trisquel:~$ sudo aptitude install ruby1.9.1
> Se instalarán los siguiente paquetes NUEVOS:
>  libruby1.9.1{a} libyaml-0-2{a} ruby1.9.1
> 0 paquetes actualizados, 3 nuevos instalados, 0 para eliminar y 7 sin
> actualizar.
> Necesito descargar 0 B/4022 kB de archivos. Después de desempaquetar se
> usarán 15,7 MB.
> ¿Quiere continuar? [Y/n/?]
> Seleccionando el paquete libyaml-0-2 previamente no seleccionado.
> (Leyendo la base de datos ... 210885 ficheros o directorios instalados
> actualmente.)
> Desempaquetando libyaml-0-2 (de .../libyaml-0-2_0.1.4-1_i386.deb) ...
> Seleccionando el paquete libruby1.9.1 previamente no seleccionado.
> Desempaquetando libruby1.9.1 (de .../libruby1.9.1_1.9.2.290-2_i386.deb) ...
> Seleccionando el paquete ruby1.9.1 previamente no seleccionado.
> Desempaquetando ruby1.9.1 (de .../ruby1.9.1_1.9.2.290-2_i386.deb) ...
> Procesando disparadores para man-db ...
> Configurando libyaml-0-2 (0.1.4-1) ...
> Configurando libruby1.9.1 (1.9.2.290-2) ...
> Configurando ruby1.9.1 (1.9.2.290-2) ...
> update-alternatives: utilizando /usr/bin/gem1.9.1 para proveer /usr/bin/gem
> (gem) en modo automático.
> update-alternatives: utilizando /usr/bin/ruby1.9.1 para proveer
> /usr/bin/ruby (ruby) en modo automático.
> Procesando disparadores para libc-bin ...
> ldconfig deferred processing now taking place
>
> quiliro@trisquel:~$ sudo gem update
> Updating installed gems
> Nothing to update
> quiliro@trisquel:~$ sudo gem install hobo
> Building native extensions.  This could take a while...
> ERROR:  Error installing hobo:
>        ERROR: Failed to build gem native extension.
>
> /usr/bin/ruby1.9.1 extconf.rb
> <internal:lib/rubygems/custom_require>:29:in `require': no such file to load
> -- mkmf (LoadError)
>        from <internal:lib/rubygems/custom_require>:29:in `require'
>        from extconf.rb:1:in `<main>'
>
>
> Gem files will remain installed in /var/lib/gems/1.9.1/gems/json-1.7.0 for
> inspection.
> Results logged to
> /var/lib/gems/1.9.1/gems/json-1.7.0/ext/json/ext/parser/gem_make.out
> quiliro@trisquel:~$
>
> --
> Saludos libres,
>
> Quiliro Ordóñez
> (593)2-253 5534
> (593)2-340 1517
> (593)9-675 9641
>
> --
> You received this message because you are subscribed to the Google Groups
> "Hobo Users" group.
> To post to this group, send email to hobo...@googlegroups.com.
> To unsubscribe from this group, send email to
> hobousers+...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/hobousers?hl=en.
>

Quiliro Ordóñez

unread,
May 3, 2012, 3:02:01 PM5/3/12
to hobo...@googlegroups.com
El 03/05/12 11:44, Bryan Larsen escribi�:
> two problems:
>
> 1) rubygems& dpkg are incompatible at the design level. In my
> opinion, it's the design of rubygems that's broken, but we have to
> live with it. So the quick answer is "never install rubygems via
> dpkg". There are several solutions, but the one I recommend for
> development boxes is to install rvm (https://rvm.io/) and then install
> ruby through that. It is possible to get Hobo to work using the
> Ubuntu supplied rubygems, but you'll probably run into problems later.
>
> 2) you're missing some build dependencies. In this case you're
> missing ruby1.9.1.dev. You could apt-get install that, but instead I
> recommend installing ruby through RVM. "rvm notes" will tell you
> exactly what you need to install for your OS.
>
> Bryan

Thank you very much for your quick help, Bryan.

I have tested your suggestion to install ruby1.9.1-dev and it has
worked. I have not used RVM because that means more software being
tested for Free System Distribution Guidelines
http://www.gnu.org/philosophy/free-system-distribution-guidelines.html

I have made a small tutorial in Spanish with an English installation script.

http://www.saslibre.com/wiki/doku.php?id=manual_de_hobo

--
Saludos libres,

Quiliro Ord��ez

Bryan Larsen

unread,
May 3, 2012, 3:11:04 PM5/3/12
to hobo...@googlegroups.com

Rvm is free:

https://github.com/wayneeseguin/rvm/blob/master/LICENCE

On May 3, 2012 3:02 PM, "Quiliro Ordóñez" <qui...@congresolibre.org> wrote:
El 03/05/12 11:44, Bryan Larsen escribió:
Quiliro Ordóńez

(593)2-253 5534
(593)2-340 1517
(593)9-675 9641

--
You received this message because you are subscribed to the Google Groups "Hobo Users" group.
To post to this group, send email to hobo...@googlegroups.com.
To unsubscribe from this group, send email to hobousers+unsubscribe@googlegroups.com.

Quiliro Ordóñez

unread,
May 3, 2012, 4:15:50 PM5/3/12
to hobo...@googlegroups.com
El 03/05/12 14:11, Bryan Larsen escribió:
Thank you for your concern. Here are our motives.

Certainly the Apache Licence 2.0 is a freedom license. Sometimes certain
developers release software under a libre (freedom respecting) license
but include only the binaries. They do not include the source code. That
makes the software nonfree. It is the case of a lot of software
including Linux (the GNU operating system kernel). It is a very lengthy
task to review this. Aditionally, RVM is an installer that might install
nonfree software. That has not been checked yet. So those two reasons
are the ones that we do not include RVM despite its ease and
functionality. If someone can finance or volunteer the review of RVM, it
could be included. Nevertheless, our resources are low for the moment
and this task must wait.

--
Saludos libres,

Quiliro Ordóñez
Reply all
Reply to author
Forward
0 new messages