Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Problems with gems and Ruby 1.8.7

73 views
Skip to first unread message

Henrique Testa

unread,
Jul 18, 2009, 9:57:53 AM7/18/09
to
Hi all,

I have ruby 1.8.7 (2008-08-11 patchlevel 72) [universal-darwin10.0]
installed in my Snow Leopard Preview Release. Rails runs OK, but I can't
install some gems with native extensions. The following error appear:

$ sudo gem install bluecloth
Password:
Building native extensions. This could take a while...
ERROR: Error installing bluecloth:
ERROR: Failed to build gem native extension.

/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby
extconf.rb
mkmf.rb can't find header files for ruby at
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/ruby.h


Gem files will remain installed in
/Library/Ruby/Gems/1.8/gems/bluecloth-2.0.5 for inspection.
Results logged to
/Library/Ruby/Gems/1.8/gems/bluecloth-2.0.5/ext/gem_make.out

The same error happens with many gems. I tried already update rubygem
(the installed version is 1.3.4), but the problem persist. Any ideas?

Thank you!

Henrique
--
Posted via http://www.ruby-forum.com/.

Henrique Testa

unread,
Jul 18, 2009, 11:38:54 PM7/18/09
to
I decided to install another version of ruby at /usr/local/ruby-1.8.6
and point executables (erb, gem, ruby, etc.) to the new ruby dir. All
went right, and ruby (1.8.6) and gem are working. But when I try to
install any gem, I get:

$ sudo gem install rails
Password:
dyld: NSLinkModule() error
dyld: Symbol not found: _ENGINE_load_4758cca
Referenced from:
/usr/local/lib/ruby/1.8/i686-darwin10.0.0b4/openssl.bundle
Expected in: flat namespace

Trace/BPT trap

It seems an error unrelated to the one before. Now I can't install any
gem :/
Any hint?

Thank you!

Eric Hodel

unread,
Jul 21, 2009, 10:07:20 PM7/21/09
to

You also have the dev tools installed?

Henrique Testa

unread,
Jul 22, 2009, 8:55:18 AM7/22/09
to
Eric Hodel wrote:
> On Jul 18, 2009, at 06:57, Henrique Testa wrote:
>> ERROR: Error installing bluecloth:

>> /Library/Ruby/Gems/1.8/gems/bluecloth-2.0.5 for inspection.
>> Results logged to
>> /Library/Ruby/Gems/1.8/gems/bluecloth-2.0.5/ext/gem_make.out
>>
>> The same error happens with many gems. I tried already update rubygem
>> (the installed version is 1.3.4), but the problem persist. Any ideas?
>
> You also have the dev tools installed?

Thank you for the response. Yes, I had... but since I didn't find a
solution, I reinstalled Leopard. It is better wait for the final release
of Snow Leopard :/

Ryan Wilson

unread,
Jul 30, 2009, 12:46:13 PM7/30/09
to


Hi I'm having the same problem, latest copy of xcode, dev tools and snow
leopard but I cant get some of the gems to build. It seems like gem
can't find the header files for Ruby...Any ideas?


Installing ri documentation for diff-lcs-1.1.2...
Installing RDoc documentation for diff-lcs-1.1.2...


Building native extensions. This could take a while...

ERROR: Error installing dnssd:


ERROR: Failed to build gem native extension.

/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby
extconf.rb
mkmf.rb can't find header files for ruby at
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/ruby.h


Gem files will remain installed in

/Library/Ruby/Gems/1.8/gems/dnssd-0.7.1 for inspection.
Results logged to
/Library/Ruby/Gems/1.8/gems/dnssd-0.7.1/ext/gem_make.out
Successfully installed echoe-3.1.1

Henrique Testa

unread,
Jul 30, 2009, 1:52:36 PM7/30/09
to
> Hi I'm having the same problem, latest copy of xcode, dev tools and snow
> leopard but I cant get some of the gems to build. It seems like gem
> can't find the header files for Ruby...Any ideas?
>
>
> Installing ri documentation for diff-lcs-1.1.2...
> Installing RDoc documentation for diff-lcs-1.1.2...
> Building native extensions. This could take a while...
> ERROR: Error installing dnssd:
> ERROR: Failed to build gem native extension.
>
> /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby
> extconf.rb
> mkmf.rb can't find header files for ruby at
> /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/ruby.h
>
>
> Gem files will remain installed in
> /Library/Ruby/Gems/1.8/gems/dnssd-0.7.1 for inspection.
> Results logged to
> /Library/Ruby/Gems/1.8/gems/dnssd-0.7.1/ext/gem_make.out
> Successfully installed echoe-3.1.1

Well, you can install other Ruby. I followed this tutorial and it worked
great:

http://www.dcmanges.com/blog/install-multiple-versions-of-ruby-on-osx-leopard

The problem with header files were gone. But the problem with
openssh.bundle I couldn't solve.

Eric Hodel

unread,
Jul 30, 2009, 7:52:14 PM7/30/09
to
On Jul 30, 2009, at 09:46, Ryan Wilson wrote:
> Henrique Testa wrote:
>> Eric Hodel wrote:
>>> On Jul 18, 2009, at 06:57, Henrique Testa wrote:
>>>> ERROR: Error installing bluecloth:
>>>> /Library/Ruby/Gems/1.8/gems/bluecloth-2.0.5 for inspection.
>>>> Results logged to
>>>> /Library/Ruby/Gems/1.8/gems/bluecloth-2.0.5/ext/gem_make.out
>>>>
>>>> The same error happens with many gems. I tried already update
>>>> rubygem
>>>> (the installed version is 1.3.4), but the problem persist. Any
>>>> ideas?
>>>
>>> You also have the dev tools installed?
>>
>> Thank you for the response. Yes, I had... but since I didn't find a
>> solution, I reinstalled Leopard. It is better wait for the final
>> release
>> of Snow Leopard :/
>
> Hi I'm having the same problem, latest copy of xcode, dev tools and
> snow
> leopard but I cant get some of the gems to build. It seems like gem
> can't find the header files for Ruby...Any ideas?
>
>
> Installing ri documentation for diff-lcs-1.1.2...
> Installing RDoc documentation for diff-lcs-1.1.2...
> Building native extensions. This could take a while...
> ERROR: Error installing dnssd:
> ERROR: Failed to build gem native extension.
>
> /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby
> extconf.rb
> mkmf.rb can't find header files for ruby at
> /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/
> ruby.h

If this file really doesn't exist you should submit a bug report to
Apple.

Elliott Pogue

unread,
Aug 13, 2009, 12:18:05 PM8/13/09
to
Installing the Xcode that's bundled with the Snow Leopard developer seed
fixed this problem for me.

Hope this helps.

Lasse Bunk

unread,
Dec 30, 2009, 8:10:53 AM12/30/09
to
Elliott Pogue wrote:
> Installing the Xcode that's bundled with the Snow Leopard developer seed
> fixed this problem for me.
>
> Hope this helps.

Also worked for me :) Thanks.

BR, Lasse

Robert Lincolne

unread,
Jan 11, 2010, 1:20:03 AM1/11/10
to
Lasse Bunk wrote:
> Elliott Pogue wrote:
>> Installing the Xcode that's bundled with the Snow Leopard developer seed
>> fixed this problem for me.
>>
>> Hope this helps.
>
> Also worked for me :) Thanks.
>
> BR, Lasse

Had the same problem, re-installed XCode with the Snow Leopard DVD we
had here fixed it.

Jeff Burrows

unread,
Dec 19, 2010, 9:49:41 PM12/19/10
to
Just wanted to confirm that I had to do this same installation of xcode
with a Macbook Pro purchased in December 2010.

Michael L.

unread,
Feb 17, 2011, 11:59:40 AM2/17/11
to
And the beat goes on...

I just had to do the same thing for a new MacBook Pro purchased
just a couple weeks ago. Good news is, this still works. Bad news is,
it's takes 9GB if you go whole hog and install xcode+iOS tools.

Tadas

unread,
Apr 21, 2011, 5:58:36 AM4/21/11
to
Michael L. wrote in post #982264:

> Bad news is, it's takes 9GB if you go whole hog and install xcode+iOS tools.

You don't actually need the iOS tools which take up most of that space.

0 new messages