Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Ruby Installing a Ruby Development Environment Installing a Ruby Development Environment Installing Ruby on Mac

hector gonzalez
hector gonzalez
14,109 Points

Problem installing ruby on Debian 7

I used rbenv to install ruby's latest version (2.1.2) but I keep getting this error:

Downloading ruby-2.1.2.tar.gz...
-> http://dqw8nmjcqpjn7.cloudfront.net/f22a6447811a81f3c808d1c2a5ce3b5f5f0955c68c9a749182feb425589e6635
Installing ruby-2.1.2...

BUILD FAILED

Inspect or clean up the working tree at /tmp/ruby-build.20140702181541.15965
Results logged to /tmp/ruby-build.20140702181541.15965.log

Last 10 log lines:
/tmp/ruby-build.20140702181541.15965/ruby-2.1.2 /tmp/ruby-build.20140702181541.15965 ~
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu
checking target system type... x86_64-unknown-linux-gnu
checking for gcc... no
checking for cc... no
checking for cl.exe... no
configure: error: in `/tmp/ruby-build.20140702181541.15965/ruby-2.1.2':
configure: error: no acceptable C compiler found in $PATH
See `config.log' for more details

BUILD FAILED

Inspect or clean up the working tree at /tmp/ruby-build.20140702181541.15965
Results logged to /tmp/ruby-build.20140702181541.15965.log

Last 10 log lines:
/tmp/ruby-build.20140702181541.15965/ruby-2.1.2 /tmp/ruby-build.20140702181541.15965 ~
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu
checking target system type... x86_64-unknown-linux-gnu
checking for gcc... no
checking for cc... no
checking for cl.exe... no
configure: error: in `/tmp/ruby-build.20140702181541.15965/ruby-2.1.2':
configure: error: no acceptable C compiler found in $PATH
See `config.log' for more details

what did you type into terminal?

1 Answer

James Barnett
James Barnett
39,199 Points

Make sure to install pre-reqs

apt-get install build-essential libssl-dev libcurl4-openssl-dev libreadline-dev -y

from: https://www.digitalocean.com/community/tutorials/how-to-install-ruby-on-rails-with-rbenv-on-debian-7-wheezy

p.s. I found this by Googling rbenv debian, it's the first result