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.

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!

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?

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 :/
Henrique

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 :/>> Henrique
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

> 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-vers...
The problem with header files were gone. But the problem with
openssh.bundle I couldn't solve.

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.

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.

Hi All,
I'm having the same problem when executing
$> sudo gem install rails
I get the error:
ERROR: Error installing rails: 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
I'm running 10.7.3 on a MacBook Air (11-inch Mid 2011 i5 CPU)
I have installed XCode v4.3 (latest) from the App Store (This computer
has no DVD drive)
I know that the ruby.h file does exist because I find it with the locate
command. It exists several places, like this:
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.6.sdk/System/Library/Frameworks/Ruby.framework/Versions/1.8/Headers/ruby.h
Perhaps my gcc environment variables need to be updated?
Any advice is greatly appreciated.
Thanks,
Rob

Rob R. wrote in post #1050146:
> Hi All,> I'm having the same problem when executing>> $> sudo gem install rails>> I get the error:>> ERROR: Error installing rails: 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>> I'm running 10.7.3 on a MacBook Air (11-inch Mid 2011 i5 CPU)>> I have installed XCode v4.3 (latest) from the App Store (This computer> has no DVD drive)>> I know that the ruby.h file does exist because I find it with the locate> command. It exists several places, like this:>
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.6.sdk/System/Library/Frameworks/Ruby.framework/Versions/1.8/Headers/ruby.h
>> Perhaps my gcc environment variables need to be updated?>> Any advice is greatly appreciated.> Thanks,> Rob
I had this particular problem as well and here's how I got around it:
For OS 10.7 + XCode4.3 only open Xcode preferences, select the
"Downloads" button, select the "Components" tab of Downloads, highlight
"Command Line Tools" and press the install button. Gem install rails
didn't give me any trouble after that. Hope that works for you too,
Chad

Chad Peterson wrote in post #1050618:
> I had this particular problem as well and here's how I got around it:> For OS 10.7 + XCode4.3 only open Xcode preferences, select the> "Downloads" button, select the "Components" tab of Downloads, highlight> "Command Line Tools" and press the install button. Gem install rails> didn't give me any trouble after that. Hope that works for you too,>> Chad
This worked great. Thanks.

> I had this particular problem as well and here's how I got around it:> For OS 10.7 + XCode4.3 only open Xcode preferences, select the> "Downloads" button, select the "Components" tab of Downloads, highlight> "Command Line Tools" and press the install button. Gem install rails> didn't give me any trouble after that. Hope that works for you too,>> Chad
This worked for me using OS 10.7.4 + Xcode 4.3.2.
todgru

> I had this particular problem as well and here's how I got around it:> For OS 10.7 + XCode4.3 only open Xcode preferences, select the> "Downloads" button, select the "Components" tab of Downloads, highlight> "Command Line Tools" and press the install button. Gem install rails> didn't give me any trouble after that. Hope that works for you too,>> Chad
This worked for me too Mac OS X 10.7.4 Xcode 4.3.3
Thanks
Mark

Posted by mark wiltshire (markemark) on 2012-07-17 18:39
> I had this particular problem as well and here's how I got around it:> For OS 10.7 + XCode4.3 only open Xcode preferences, select the> "Downloads" button, select the "Components" tab of Downloads, highlight> "Command Line Tools" and press the install button. Gem install rails> didn't give me any trouble after that. Hope that works for you too,
It did work for me thank you so much :)

Ruby Sea wrote in post #1070503:
> Posted by mark wiltshire (markemark) on 2012-07-17 18:39>> I had this particular problem as well and here's how I got around it:>> For OS 10.7 + XCode4.3 only open Xcode preferences, select the>> "Downloads" button, select the "Components" tab of Downloads, highlight>> "Command Line Tools" and press the install button. Gem install rails>> didn't give me any trouble after that. Hope that works for you too,>>> It did work for me thank you so much :)
Seems to work with OS 10.8 and XCode 4.4 as well - same problem
encountered - same solution - thanks so much for the help

> I had this particular problem as well and here's how I got around it:> For OS 10.7 + XCode4.3 only open Xcode preferences, select the> "Downloads" button, select the "Components" tab of Downloads, highlight> "Command Line Tools" and press the install button. Gem install rails> didn't give me any trouble after that. Hope that works for you too,>> Chad
This WORKED! Thank you..

> I had this particular problem as well and here's how I got around it:> For OS 10.7 + XCode4.3 only open Xcode preferences, select the> "Downloads" button, select the "Components" tab of Downloads, highlight> "Command Line Tools" and press the install button. Gem install rails> didn't give me any trouble after that. Hope that works for you too,>> Chad
This worked for me as well. Thank you!