Forum: Ruby gem + libxml

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.
Ddefb01aec51d43443f4afe24d134fed?d=identicon&s=25 Mikael Larsson (Guest)
on 2006-03-10 21:47
(Received via mailing list)
Hi

Wat is wrong here ?? Do I need ruby source?

linux:~ #
linux:~ # ruby -v
ruby 1.8.2 (2004-12-25) [i586-linux]
linux:~ # gem -v
0.8.11
linux:~ # gem install libxml-ruby
Attempting local installation of 'libxml-ruby'
Local gem file not found: libxml-ruby*.gem
Attempting remote installation of 'libxml-ruby'
Building native extensions.  This could take a while...
can't find header files for ruby.
ERROR:  While executing gem ... (RuntimeError)
    ERROR: Failed to build gem native extension.
Gem files will remain installed in
/usr/lib/ruby/gems/1.8/gems/libxml-ruby-0.3.6 for inspection.
  ruby extconf.rb install libxml-ruby\n

Results logged to
/usr/lib/ruby/gems/1.8/gems/libxml-ruby-0.3.6/ext/xml/gem_make.out
linux:~ # cat
/usr/lib/ruby/gems/1.8/gems/libxml-ruby-0.3.6/ext/xml/gem_make.out
ruby extconf.rb install libxml-ruby
linux:~ #

Thanks

//Mike
A9b6a93b860020caf9d2d1d58c32478f?d=identicon&s=25 Ross Bamford (Guest)
on 2006-03-11 09:37
(Received via mailing list)
On Sat, 2006-03-11 at 05:45 +0900, Mikael Larsson wrote:
> Attempting local installation of 'libxml-ruby'
> Results logged to
> /usr/lib/ruby/gems/1.8/gems/libxml-ruby-0.3.6/ext/xml/gem_make.out
> linux:~ # cat
> /usr/lib/ruby/gems/1.8/gems/libxml-ruby-0.3.6/ext/xml/gem_make.out
> ruby extconf.rb install libxml-ruby
> linux:~ #

Hmm, I think that the Ruby headers should always be installed, in your
case it looks like they should be at:

	/usr/lib/ruby/1.8/i586-linux/

Could you verify the presence (or absence) of a bunch of .h files at
that location? If they're not there, then you should probably grab a new
Ruby install (is this one a package from your distro?).
Ddefb01aec51d43443f4afe24d134fed?d=identicon&s=25 Mikael Larsson (Guest)
on 2006-03-11 10:23
(Received via mailing list)
Ross Bamford wrote:
>> 0.8.11
>>   ruby extconf.rb install libxml-ruby\n
>> -rwxr-xr-x  1 root root  17212 2006-01-26 15:02 dbm.so
>> -rwxr-xr-x  1 root root 217928 2006-01-26 15:02 openssl.so
>> -rwxr-xr-x  1 root root  33008 2006-01-26 15:02 zlib.so
> Ruby install (is this one a package from your distro?).
>
>
found this
micke@linux:~/dvl/nexus/nexpre> ll /usr/lib/ruby/1.8/i586-linux/
total 864
-rwxr-xr-x  1 root root  39492 2006-01-26 15:02 bigdecimal.so
-rwxr-xr-x  1 root root  43408 2006-01-26 15:02 curses.so
-rwxr-xr-x  1 root root  17212 2006-01-26 15:02 dbm.so
drwxr-xr-x  2 root root    152 2006-03-03 09:30 digest
-rwxr-xr-x  1 root root   7236 2006-01-26 15:02 digest.so
-rwxr-xr-x  1 root root  72872 2006-01-26 15:02 dl.so
-rwxr-xr-x  1 root root   6904 2006-01-26 15:02 enumerator.so
-rwxr-xr-x  1 root root   8144 2006-01-26 15:02 etc.so
-rwxr-xr-x  1 root root   4364 2006-01-26 15:02 fcntl.so
-rwxr-xr-x  1 root root  18552 2006-01-26 15:02 gdbm.so
-rwxr-xr-x  1 root root  13036 2006-01-26 15:02 iconv.so
drwxr-xr-x  2 root root     72 2006-03-03 09:30 io
-rwxr-xr-x  1 root root 135712 2006-01-26 15:02 nkf.so
-rwxr-xr-x  1 root root 217928 2006-01-26 15:02 openssl.so
-rwxr-xr-x  1 root root   8960 2006-01-26 15:02 pty.so
drwxr-xr-x  2 root root     80 2006-03-03 09:30 racc
-rw-r--r--  1 root root   6619 2006-01-26 15:00 rbconfig.rb
-rwxr-xr-x  1 root root  14972 2006-01-26 15:02 readline.so
-rwxr-xr-x  1 root root  22940 2006-01-26 15:02 sdbm.so
-rwxr-xr-x  1 root root  35688 2006-01-26 15:02 socket.so
-rwxr-xr-x  1 root root  16708 2006-01-26 15:02 stringio.so
-rwxr-xr-x  1 root root  15552 2006-01-26 15:02 strscan.so
-rwxr-xr-x  1 root root  89536 2006-01-26 15:02 syck.so
-rwxr-xr-x  1 root root  10560 2006-01-26 15:02 syslog.so
-rwxr-xr-x  1 root root  33008 2006-01-26 15:02 zlib.so

Ruby comes with distro ( SUSE 10)

//Mike
A9b6a93b860020caf9d2d1d58c32478f?d=identicon&s=25 Ross Bamford (Guest)
on 2006-03-11 10:35
(Received via mailing list)
On Sat, 2006-03-11 at 18:22 +0900, Mikael Larsson wrote:
> >> linux:~ # gem -v
> >> /usr/lib/ruby/gems/1.8/gems/libxml-ruby-0.3.6 for inspection.
> > Ruby install (is this one a package from your distro?).
> -rwxr-xr-x  1 root root  72872 2006-01-26 15:02 dl.so
> -rw-r--r--  1 root root   6619 2006-01-26 15:00 rbconfig.rb
>
> //Mike

Okay, it seems you're missing the headers. Couple of things you might
try:

	+ Does Suse have a ruby-devel package ? If so, get that.

	+ Beg/borrow/steal the appropriate headers, and copy them to
	  that directory (maybe not a good idea).

	+ Alternatively, grab a copy of the source and build it
	  yourself. You could upgrade to 1.8.4 at the same time ;)
Ddefb01aec51d43443f4afe24d134fed?d=identicon&s=25 Mikael Larsson (Guest)
on 2006-03-11 10:53
(Received via mailing list)
Ross Bamford wrote:
>>>>
>>>> can't find header files for ruby.
>>> 	/usr/lib/ruby/1.8/i586-linux/
>> -rwxr-xr-x  1 root root  39492 2006-01-26 15:02 bigdecimal.so
>> drwxr-xr-x  2 root root     72 2006-03-03 09:30 io
>> -rwxr-xr-x  1 root root  89536 2006-01-26 15:02 syck.so
>
> 	+ Does Suse have a ruby-devel package ? If so, get that.
>
> 	+ Beg/borrow/steal the appropriate headers, and copy them to
> 	  that directory (maybe not a good idea).
>
> 	+ Alternatively, grab a copy of the source and build it
> 	  yourself. You could upgrade to 1.8.4 at the same time ;)
>
>
There was a ruby-devel pakage, now it works!! Thanks for your help

//Mike
This topic is locked and can not be replied to.