![](/img/trans.png)
[英]Problem installing rspec-1.3.2 on Lion using RVM and ruby 1.8.6
[英]Lion: Problem with RVM installing rubies - problem related to openssl
我已經絕望了,現在兩個(!!)天都沒有解決方案來解決以下問題。
在更新Lion之后,我想使用最新版本的rvm安裝其他紅寶石。
以下是我之后調用bundler時會發生的事情:
/Users/felix/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require': dlopen(/Users/janroesner/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/x86_64-darwin11.1.0/digest/sha1.bundle, 9): Symbol not found: _SHA1_Init (LoadError)
好的,openssl問題。 所以我檢查了沒有openssl但是/ usr中的系統有/ usr / lib中的庫和/ usr / include / openssl中的頭文件。 校驗。
我決定用brew安裝一個更新的版本。 之后,沒有ruby編譯已經定義了BN_rand_range和BN_peudo_rand_range的錯誤。
似乎是對最近的gcc進行更嚴格的類型檢查,所以我在/usr/include/openssl/bn.h中取消注釋導致沖突的411和412行導致ruby定義了它自己。 現在ruby編譯但我收到相同的錯誤符號未找到:_SHA1_Init。
所以我刪除了openssl頭文件bn.h中的注釋,我之前放在那里並嘗試相反的方法。 我在〜/ .rvm / src / ruby-1.9.2-p290 / ext / openssl / openssl_missing.h中對這些行進行了評論。
結果相同。
之后我完全刪除了〜/ .rvm,重新安裝它......並且有同樣的問題。
現在我試過了:
rvm pkg install openssl
rvm remove 1.9.2-p290
rvm install 1.9.2-p290 -C --with-openssl-dir=$rvm_path/usr
結果相同。
我很絕望。 有人可以幫忙嗎? 問菲利克斯
對於任何應該在Lion上遇到此問題的人來說......這是來自openssl的重復標題的一些問題。 您可以在本地安裝openssl並告訴rvm使用該本地openssl版本。
您可以使用前綴/ usr / local手動編譯opnessl,或者只是讓rvm完成工作:
rvm pkg install openssl
然后告訴rvm在ruby安裝期間鏈接該版本:
rvm install 1.9.2 --with-openssl-dir=/path/to/your/home/.rvm/usr
如果您已經有本地安裝替換為:
rvm install 1.9.2 --with-openssl-dir=/usr/local
不要嘗試經常閱讀的內容:
rvm install 1.9.2 -C --with-openssl-dir=/path/to/your/home/.rvm/usr
這不起作用。
我剛剛完成了本教程,它沒有任何問題:Rails Up: http : //www.frederico-araujo.com/2011/07/30/installing-rails-on-os-x-lion-with-homebrew -rvm和- MySQL的/
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.