2013-07-29 94 views
5

我的最終目標是安裝當前版本的Ruby on Rails。我在OS X Mountain Lion上運行。這裏是我的進程迄今:無法通過RVM安裝Ruby 2.0.0-p247(OSX Mountain Lion)

安裝RVM

$ \curl -L https://get.rvm.io | bash -s stable 

檢查已知的(我假設批准)安裝

$ rvm list known 

我看到,當前穩定版本可

[ruby-]2.0.0[-p247] 

鍵入命令安裝

$ rvm install 2.0.0-p247 

注:我也嘗試過這些安裝我越來越無處快命令

$ rvm install ruby-2.0.0-p247 
$ rvm install ruby=2.0.0-p247 

。結果:

$ rvm install 2.0.0-p247 
Searching for binary rubies, this might take some time. 
No binary rubies available for: osx/10.8/x86_64/ruby-2.0.0-p247. 
Continuing with compilation. Please read 'rvm help mount' to get more information on binary rubies. 
Installing requirements for osx, might require sudo password. 
Certificates in '/usr/local/etc/openssl/cert.pem' already are up to date. 
Requirements installation successful. 
Installing Ruby from source to: /Users/xxxxx/.rvm/rubies/ruby-2.0.0-p247, this may take a while depending on your cpu(s)... 
ruby-2.0.0-p247 - #downloading ruby-2.0.0-p247, this may take a while depending on your connection... 
ruby-2.0.0-p247 - #extracted to /Users/xxxxx/.rvm/src/ruby-2.0.0-p247 (already extracted) 
ruby-2.0.0-p247 - #configuring........ 
Error running './configure --prefix=/Users/xxxxx/.rvm/rubies/ruby-2.0.0-p247 --with-opt-dir=/usr/local/opt/libyaml:/usr/local/opt/readline:/usr/local/opt/libksba:/usr/local/opt/openssl --disable-install-doc --without-tcl --without-tk --enable-shared', 
please read /Users/xxxxx/.rvm/log/ruby-2.0.0-p247/1375141206_configure.log 
There has been an error while running configure. Halting the installation. 

我也在調試模式下運行這個命令。爲了避免混亂,你可以訪問它here

而且,這裏是日誌:

./configure 
current path: /Users/xxxxx/.rvm/src/ruby-2.0.0-p247 
command(7): ./configure --prefix=/Users/xxxxx/.rvm/rubies/ruby-2.0.0-p247 --with-opt-dir=/usr/local/opt/libyaml:/usr/local/opt/readline:/usr/local/opt/libksba:/usr/local/opt/openssl --disable-install-doc --without-tcl --without-tk --enable-shared 
configure: WARNING: unrecognized options: --without-tcl, --without-tk 
checking build system type... x86_64-apple-darwin12.2.1 
checking host system type... x86_64-apple-darwin12.2.1 
checking target system type... x86_64-apple-darwin12.2.1 
checking whether the C compiler works... no 
configure: error: in `/Users/xxxxx/.rvm/src/ruby-2.0.0-p247': 
configure: error: C compiler cannot create executables 
See `config.log' for more details 

這是我通過RVM第一安裝。 $ rvm列表不返回任何寶石。

請詢問是否有其他信息可能有幫助。

編輯 - HERE是可以幫助任何人的登錄情況。

+0

後,試圖重新開始我的整個過程從頭開始。現在重新安裝Xcode和命令行工具 - 然後我會再試一次。我會在可用時發佈我的結果。 – MrCarder

+1

請加上'/ Users/xxxxx/.rvm/src/ruby​​-2.0.0 -p247/config.log' – mpapis

+0

我想出了這個問題(種類)。如果我發佈日誌,它會對他人有幫助嗎? – MrCarder

回答

4

我的Xcode或我的命令行工具安裝一定是錯誤的。重新安裝都使得一切都運行良好。

+0

你是如何卸載命令行工具的? – Clone

+3

由於您的答案缺乏技術深度並建議這樣一個低效率的流程,因此得不到支持。 – JGallardo

1

請確保您在XCode中安裝命令行工具,因爲它不會自動執行(是的,我同意命令行工具應該默認安裝),但事實並非如此。

安裝的XCode - >首選項 - >下載 - >「命令行工具」

編輯*錯過了整個「造萬物運行精美一部分」,並輸入這一切OUT-

乾杯,很高興一切工作出來了!

3

對於那些來到這裏,從谷歌,當你應用了相同的錯誤查詢:

我有同樣的問題,但不希望要經過冗長得可笑的重新安裝的Xcode喜歡接受的答案的過程建議。我所做的只是運行
rvm get stable然後運行
rvm install ruby-2.0.0-p247再次

我原來的問題

problem

然後我跑
rvm get stable

Solution

相關問題