ruby-1.9.3-p0 - #configuring
*ERROR: Error running ' ./configure --prefix=/Users/davedelich/.rvm/rubies/ruby-1.9.3-p0 --enable-shared --disable-install-doc --with-libyaml-dir=/Users/davedelich/.rvm/usr ', please read /Users/davedelich/.rvm/log/ruby-1.9.3-p0/configure.log
ERROR: There has been an error while running configure. Halting the installation.*
SupremeOverlord:~ davedelich$ cat /Users/davedelich/.rvm/log/ruby-1.9.3-p0/configure.log
[2011-12-03 22:09:03] ./configure --prefix=/Users/davedelich/.rvm/rubies/ruby-1.9.3-p0 --
enable-shared --disable-install-doc --with-libyaml-dir=/Users/davedelich/.rvm/usr
configure: WARNING: unrecognized options: --with-libyaml-dir
checking build system type... x86_64-apple-darwin11.2.0
checking host system type... x86_64-apple-darwin11.2.0
checking target system type... x86_64-apple-darwin11.2.0
checking whether the C compiler works... no
configure: error: in `/Users/davedelich/.rvm/src/ruby-1.9.3-p0':
configure: error: C compiler cannot create executables
See `config.log' for more details
Asked
Active
Viewed 6,338 times
7

Andrew Marshall
- 95,083
- 20
- 220
- 214

ironmayne
- 71
- 1
- 2
-
So, what's in `config.log`? Do you have Xcode installed? What is the output of `which gcc`? – Andrew Marshall Dec 04 '11 at 03:23
-
I can echo this problem. New iMac running the latest Lion and Xcode installed. I can install 1.9.2 no problem but 1.9.3 fails to configure. which gcc points to gcc in /usr/bin/. I am starting to think I need both the "osx-gcc-installer" and Xcode? – Martin Westin Dec 17 '11 at 13:19
-
2It cracks me up that this was closed as not "related to software development in some way." Seriously, I don't understand the rush to close topics on SO. Google brought me to this question because I'm trying to set up Rails to, you know, do some programming... – Brian Moeskau Mar 02 '12 at 05:58
1 Answers
3
There is no C compiler installed on your system -- this means that you have to install XCode on your Mac!! It contains all development tools, including the compiler.
check your OSX DVD or memory stick for XCode, or check online at Apple:
http://developer.apple.com/xcode/
http://developer.apple.com/technologies/tools/
http://www.macworld.com/article/46286/2005/08/installxcode.html

Tilo
- 33,354
- 5
- 79
- 106
-
7For me Xcode wasn't enough. I also needed to install osx-gcc-installer to get 1.9.3 to compile. – Martin Westin Dec 17 '11 at 13:31
-
2Same for me. MacBook running Lion and latest Xcode and I got the same error as above. I followed Martin's tip and I installed osx-gcc-installer and then it worked. I found it here: http://mac.softpedia.com/get/Development/Compilers/OSX-GCC-Installer.shtml – Keith Schacht Dec 17 '11 at 20:09
-
I just got a new MacBook Pro from work with Lion, and installing XCode was enough to get this working. One problem is that "installing XCode" is just installing the "Xcode installer" .. which still needs to be run separately. – Tilo Dec 18 '11 at 00:57
-
5just doing 'rvm install 1.9.3 --with-gcc=clang' worked for me on a new MacBook with XCode 4.2; see Arkku's answer here: http://stackoverflow.com/questions/8032824/cant-install-ruby-under-lion-with-rvm-gcc-issues – Andrea Jan 19 '12 at 01:08