2013-05-14 1 views
2

그래서 제 고객은 Rails 2.3.8과 Ruby 1.8.7을 실행하는 기존 앱을 설치하려고합니다. 루비의 적절한 버전 rbenv 사용하지만 나에게이 오류주고 계속 : 내가 GCC를 가지고 있는지 확인하기 위해이 옵션을 선택하면rbenv 설치가 실패했습니다 (GCC 설치를 말하지 만 이미 설치되어 있음)

→ rbenv install 1.8.7-p249 

ERROR: This package must be compiled with GCC, but ruby-build couldn't 
find a suitable `gcc` executable on your system. Please install GCC 
and try again. 

DETAILS: Apple no longer includes the official GCC compiler with Xcode 
as of version 4.2. Instead, the `gcc` executable is a symlink to 
`llvm-gcc`, a modified version of GCC which outputs LLVM bytecode. 

For most programs the `llvm-gcc` compiler works fine. However, 
versions of Ruby older than 1.9.3-p125 are incompatible with 
`llvm-gcc`. To build older versions of Ruby you must have the official 
GCC compiler installed on your system. 


TO FIX THE PROBLEM: Install the official GCC compiler using these 
packages: https://github.com/kennethreitz/osx-gcc-installer/downloads 

You will need to install the official GCC compiler to build older 
versions of Ruby even if you have installed Apple's Command Line Tools 
for Xcode package. The Command Line Tools for Xcode package only 
includes `llvm-gcc`. 

BUILD FAILED 

를, 내가 할 것으로 나타났다 :

→ which gcc 
/usr/bin/gcc 

→ gcc -v 

Using built-in specs. 
Target: i686-apple-darwin11 
Configured with: /private/var/tmp/llvmgcc42/llvmgcc42-2336.11~148/src/configure --disable- checking --enable-werror --prefix=/Applications/Xcode.app/Contents/Developer/usr/llvm-gcc-4.2 --mandir=/share/man --enable-languages=c,objc,c++,obj-c++ --program-prefix=llvm- --program-transform-name=/^[cg][^.-]*$/s/$/-4.2/ --with-slibdir=/usr/lib --build=i686-apple-darwin11 --enable-llvm=/private/var/tmp/llvmgcc42/llvmgcc42-2336.11~148/dst-llvmCore/Developer/usr/local --program-prefix=i686-apple-darwin11- --host=x86_64-apple-darwin11 --target=i686-apple-darwin11 --with-gxx-include-dir=/usr/include/c++/4.2.1 
Thread model: posix 
gcc version 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2336.11.00) 

나는 rbenv를 업데이트했습니다. 정말 무엇을 해야할지 잘 모릅니다.

+0

관련이 있는지 확실하지 않은 RVM의 비슷한 문제가 발견되었지만 몇 가지 해결책을 시도해 보겠습니다. http://stackoverflow.com/questions/8032824/cant-install-ruby-under-lion -with-rvm-gcc-issues? rq = 1 – jarodtaylor

답변

1

전체 오류를 완전히 읽지 않아도됩니다. :)

gcc가 아닌 llvmgcc42가 설치되었습니다. 이전 버전의 Ruby에는 GCC가 필요했습니다.

관련 문제