My Rails is 3.2.1.4
, Ruby is 1.9.3p448
.
I got an error when I install ruby-debug
:
Building native extensions.
It seems to be a issue with permission of gcc.. however, if you're using OS X, you may encounter this issue if you've updated your XCode but haven't agree to their terms & conditions yet.. try typing gcc
in your terminal would show you what if you've agreed.
My mkmf.log showed that gcc (4.8.2 I think) didn't like a specific argument that was being used by atomic on
$ gem install atomic
So I had a very similar situation. The answer for me was to upgrade gcc/gcc-libs and lib tool.
I use Arch linux, and only Arch linux. The proper way to do this is to run
$ sudo pacman -Syu
which upgrades all system packages.
I installed Rails and hadn't run a system update since, which is where the issue came from. In most other *nix distros, you would update to the latest version of these packages by name, i.e. with apt, it would be something along the lines of
$ sudo apt-get update
followed by
$ sudo apt-get upgrade {package-name}
I had the issue because gcc
wasn't available on my machine.
Fixed it by installing gcc
.
sudo apt install build-essential