172

I'm attempting to re-install Ruby 1.9.3 with a patch that will allow me to use ruby-debug.

When following the instructions and running

rvm reinstall 1.9.3 --patch debug --force-autoconf

It runs through and after applying the patch spits out:

rvm requires autoreconf to install the selected ruby interpreter however autoreconf was not found in the PATH.

Unfortunately, googling around for how to install autoreconf on OS X v10.7 (Lion) (or much information about it at all) seems to be a dead end.

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
Brian
  • 7,204
  • 12
  • 51
  • 84
  • 1
    You don't have to patch 1.9.3 to use ruby-debug—see [this question](http://stackoverflow.com/questions/8087610/ruby-debug-with-ruby-1-9-3). – Andrew Marshall Mar 06 '12 at 00:01
  • other thing is you most likely used `command line tools` which is missing `auto*` tools, and provides only LLVM compiler - no real GCC, that will be a problem when compiling ruby-1.9.3-p0 or lower versions – mpapis Mar 06 '12 at 01:05

6 Answers6

366

If you are using Homebrew, try

brew install automake

Which should also install autoconf and allow rvm to finish installing.

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
foz
  • 5,230
  • 2
  • 23
  • 15
43

If you want to do this using MacPorts instead of Homebrew, you can do:

sudo port install automake autoconf libtool

I had the same problem and this solved it for me.

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
patr1ck
  • 964
  • 7
  • 13
  • This didn't seem to add autoconf to my path. – Erik Jan 15 '14 at 18:12
  • Hey Erik, are you sure macports is setup correctly? Can you see /opt/local/bin and related directories in your path? – patr1ck Jan 15 '14 at 22:37
  • In case someone has problem with libtool and glibtool, this is the way it has been ported in macports: https://lists.macosforge.org/pipermail/macports-users/2009-October/017432.html – Kyr Nov 09 '15 at 15:59
9

If you're using brew, then the autoreconf utility is part of the autoconf package, so install it via:

brew install autoconf

If the problem persists, consider either reinstall or link it again. Use locate autoreconf to find out where it is.

Also check if /usr/local/bin/autoreconf exists (and is linked into the right place), and you've the /usr/local/bin path added in your /etc/paths file.

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
kenorb
  • 155,785
  • 88
  • 678
  • 743
2

By downloading the .pkg file from MacPorts and installing it, it does the trick for me.

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
Inder Kumar Rathore
  • 39,458
  • 17
  • 135
  • 184
1

I had a similar problem, but because Homebrew moved away from the Cellar directory, but for some reasons binaries of this package were still there.

I reinstalled autoconf with the following command and autoreconf is in the right PATH now: brew reinstall autoconf

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
Tom
  • 834
  • 1
  • 14
  • 24
0

I solved my autoreconf problem adding the path to my shell:

sudo pico /etc/paths

then I added the line

/sw/bin

where I found the autoreconf and autoconf files and saved everything.

Since then I can use autoreconf without any problems.

kenorb
  • 155,785
  • 88
  • 678
  • 743