Forum: Ruby nokogirl on ubuntu: failed to build gem native extension

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Edouard D. (Guest)
on 2009-01-27 09:10
Hi,

I want to give a try to nokogiri with mechanize as it seems to have
encoding methods.

I run ubuntu heron and installed the libraries libxslt1-dev libxml2
libxml2-dev.

now when i run sudo gem install nokogiri i get this error log:

ruby extconf.rb install nokogiri-1.1.1.gem
extconf.rb:3:in `require': no such file to load -- mkmf (LoadError)
  from extconf.rb:3

I don't get what's missing here?

thanks for comments.
Radosław B. (Guest)
on 2009-01-27 09:52
(Received via mailing list)
Search and install package named ruby-dev. Notice also that it's
nokogiri (last letter is 'i').


--
Pozdrawiam

Rados³aw Bu³at
http://radarek.jogger.pl - mój blog
Alice G. (Guest)
on 2009-05-27 23:52
Radosław Bułat wrote:
> Search and install package named ruby-dev.
Have similar problem and tried to install ruby-dev but it is not in my
system
I am on linux ( CentOS release 5.2 (Final) How do I go about installing
it?
>Notice also that it's
> nokogiri (last letter is 'i').
>
>
> --
> Pozdrawiam
>
> Rados�aw Bu�at
> http://radarek.jogger.pl - m�j blog
Charles J. (Guest)
on 2009-05-28 00:13
(Received via mailing list)
On May 27, 2009, at 2:52 PM, Alice Gheorghiu wrote:

> Radosław Bułat wrote:
>> Search and install package named ruby-dev.
> Have similar problem and tried to install ruby-dev but it is not in my
> system
> I am on linux ( CentOS release 5.2 (Final) How do I go about
> installing
> it?
This should get you started:

http://is.gd/HmzB

Cheers--

Charles
---
Charles J.
Advanced Computing Center for Research and Education
Vanderbilt University
Alice G. (Guest)
on 2009-05-28 21:55
Attachment: errorOnInstallmechanize (0 Bytes)
Charles J. wrote:
> On May 27, 2009, at 2:52 PM, Alice Gheorghiu wrote:
>
>> Radosław Bułat wrote:
>>> Search and install package named ruby-dev.
>> Have similar problem and tried to install ruby-dev but it is not in my
>> system
>> I am on linux ( CentOS release 5.2 (Final) How do I go about
>> installing
>> it?
> This should get you started:
>
> http://is.gd/HmzB
Tried it and also followed this site http://whomwah.com/tag/howto/ for
my specific OS to no avail. Maybe I need to modify the conf file (I
attached file with execution for review)
Thanks a bunch for all the help -- alice
>
> Cheers--
>
> Charles
> ---
> Charles J.
> Advanced Computing Center for Research and Education
> Vanderbilt University
Eric H. (Guest)
on 2009-05-29 01:35
(Received via mailing list)
On May 27, 2009, at 12:52, Alice Gheorghiu wrote:

> Radosław Bułat wrote:
>> Search and install package named ruby-dev.
> Have similar problem and tried to install ruby-dev but it is not in my
> system
> I am on linux ( CentOS release 5.2 (Final) How do I go about
> installing
> it?
>> Notice also that it's
>> nokogiri (last letter is 'i').

Sorry, I lost the original, but there is a nokogirl gem:

$ gem list -r nokogir

*** REMOTE GEMS ***

nokogiri (1.2.3)
nokogirl (1.0)
$ gem dep -r nokogirl
Gem nokogirl-1.0
   nokogiri (>= 0, runtime)
Alice G. (Guest)
on 2009-05-29 03:12
Eric H. wrote:
> On May 27, 2009, at 12:52, Alice Gheorghiu wrote:
>
>Radosław Bułat wrote:
>Search and install package named ruby-dev.
>Have similar problem and tried to install ruby-dev but it is not in my
>system
>I am on linux ( CentOS release 5.2 (Final) How do I go about
>installingit?
>Notice also that it's nokogiri (last letter is 'i').
>
> Sorry, I lost the original, but there is a nokogirl gem:

> $ gem list -r nokogir
>
> *** REMOTE GEMS ***

nokogiri (1.2.3)
nokogirl (1.0)
$ gem dep -r nokogirl
Gem nokogirl-1.0
nokogiri (>= 0, runtime)

I tried it too and it's there. What's the point? Should we try to
install nokogirl instead?
Eric H. (Guest)
on 2009-05-29 03:36
(Received via mailing list)
On May 28, 2009, at 16:12, Alice Gheorghiu wrote:

>> Notice also that it's nokogiri (last letter is 'i').
> Gem nokogirl-1.0
> nokogiri (>= 0, runtime)
>
> I tried it too and it's there. What's the point? Should we try to
> install nokogirl instead?

IIRC, Mike D. always typed "nokogirl" instead of "nokogiri", so
he released "nokogirl"
Mike D. (Guest)
on 2009-05-29 06:11
(Received via mailing list)
2009/5/28 Eric H. <removed_email_address@domain.invalid>

>>>
>> nokogiri (>= 0, runtime)
>>
>> I tried it too and it's there. What's the point? Should we try to
>> install nokogirl instead?
>>
>
> IIRC, Mike D. always typed "nokogirl" instead of "nokogiri", so he
> released "nokogirl"
>

Since I was a small boy, I have always wanted to be famous for my poor
typing skills. So, I would love to sit back and let this particular
piece of
urban mythology propagate.

However, nokogirl is just too damn funny to not give credit where it is
due:

   http://judofyr.net/posts/nokogirl.html

Carry on.
Alice G. (Guest)
on 2009-05-29 09:48
Mike D. wrote:
> 2009/5/28 Eric H. <removed_email_address@domain.invalid>
>
>>>>
>>> nokogiri (>= 0, runtime)
>>>
>>> I tried it too and it's there. What's the point? Should we try to
>>> install nokogirl instead?
>> IIRC, Mike D. always typed "nokogirl" instead of "nokogiri", so he
>> released "nokogirl"

> Since I was a small boy, I have always wanted to be famous for my poor
> typing skills. So, I would love to sit back and let this particular
> piece of
> urban mythology propagate.

> However, nokogirl is just too damn funny to not give credit where it is
> due:
>
>    http://judofyr.net/posts/nokogirl.html

> Carry on.

LOL -with tears in my eyes! Worked on a wget today, with the help of my
provider and it's a nice solution instead of the mechanize module I was
hoping to install from this nokogiri(l) or whatever. I'll keep trying
for my other data provider and ...Stay tuned!. In the meantime if
there's any ruby expert with a bit of time to review the attachement,
maybe I am missing something.
Alice G. (Guest)
on 2009-06-02 01:56
Alice Gheorghiu wrote:
> Mike D. wrote:
>> 2009/5/28 Eric H. <removed_email_address@domain.invalid>
>>
>>>>>
>>>> nokogiri (>= 0, runtime)
>>>>
>>>> I tried it too and it's there. What's the point? Should we try to
>>>> install nokogirl instead?
>>> IIRC, Mike D. always typed "nokogirl" instead of "nokogiri", so he
>>> released "nokogirl"
>
>> Since I was a small boy, I have always wanted to be famous for my poor
>> typing skills. So, I would love to sit back and let this particular
>> piece of
>> urban mythology propagate.
>
>> However, nokogirl is just too damn funny to not give credit where it is
>> due:
>>
>>    http://judofyr.net/posts/nokogirl.html
>
>> Carry on.
>
> LOL -with tears in my eyes! Worked on a wget today, with the help of my
> provider and it's a nice solution instead of the mechanize module I was
> hoping to install from this nokogiri(l) or whatever. I'll keep trying
> for my other data provider and ...Stay tuned!. In the meantime if
> there's any ruby expert with a bit of time to review the attachement,
> maybe I am missing something.

The issue on my installation was that libxml2 appeared in my /usr/lib64
directory as libxml2.so.2, libxml2.so.2.6.26, and libxml2-2.6.26 so the
configuration file could not determine which one to use. By making a
symbolic link to the latest version libsml2.so.2.6.26 resolved the
problem. Both nokogiri and mechanize were successfully installed
Reza N. (Guest)
on 2011-01-30 01:26
Hi Alice

Could you please tell me WHICH config file you changed or how? I'm
porting a tiny app from Windows to Ubunto and nokogiri port is one of
the problems I've had so far.

Thnaks
Mike D. (Guest)
on 2011-01-31 16:31
(Received via mailing list)
Greetings and salutations!


On Sat, Jan 29, 2011 at 6:26 PM, Reza N. <removed_email_address@domain.invalid> 
wrote:

> Hi Alice
>
> Could you please tell me WHICH config file you changed or how? I'm
> porting a tiny app from Windows to Ubunto and nokogiri port is one of
> the problems I've had so far.
>
>
The thread you've posted to is over a year and a half old! That's
ancient.

You may get better responses if you described what your issue is,
attaching
information about your Ubuntu version, libxml2 and libxslt versions, and
the
contents of your mkmf.log file after the failed gem installation.

Hint: you may want to check out
http://nokogiri.org/tutorials/installing_nokogiri.html
This topic is locked and can not be replied to.