Ruby-build giving me Autoconf version 2.67 or higher is required - ruby

Trying to install Ruby 2.2.0-dev using ruby-build gives me an error about Autoconf:
$ rbenv install 2.2.0-dev
Cloning https://github.com/ruby/ruby.git...
Installing ruby-2.2.0-dev...
BUILD FAILED
Inspect or clean up the working tree at /var/folders/3x/y_8y8vr53ws_kxj97km79q5h0000gn/T/ruby-build.20140107115843.2294
Results logged to /var/folders/3x/y_8y8vr53ws_kxj97km79q5h0000gn/T/ruby-build.20140107115843.2294.log
Last 10 log lines:
/var/folders/3x/y_8y8vr53ws_kxj97km79q5h0000gn/T/ruby-build.20140107115843.2294 ~/bogus/path
Cloning into 'ruby-2.2.0-dev'...
/var/folders/3x/y_8y8vr53ws_kxj97km79q5h0000gn/T/ruby-build.20140107115843.2294/ruby-2.2.0-dev /var/folders/3x/y_8y8vr53ws_kxj97km79q5h0000gn/T/ruby-build.20140107115843.2294 ~/bogus/path
configure.in:6: error: Autoconf version 2.67 or higher is required
configure.in:6: the top level
autom4te: /usr/bin/gm4 failed with exit status: 63
Homebrew seems to claim that autoconf 2.69 is available. Unless it's only using autoconf for itself, without allowing it to be used by others:
$ brew list autoconf
/usr/local/Cellar/autoconf/2.69/bin/ifnames
/usr/local/Cellar/autoconf/2.69/bin/autoupdate
/usr/local/Cellar/autoconf/2.69/bin/autoscan
/usr/local/Cellar/autoconf/2.69/bin/autoreconf
/usr/local/Cellar/autoconf/2.69/bin/autom4te
/usr/local/Cellar/autoconf/2.69/bin/autoheader
/usr/local/Cellar/autoconf/2.69/bin/autoconf
/usr/local/Cellar/autoconf/2.69/share/autoconf/ (42 files)
/usr/local/Cellar/autoconf/2.69/share/emacs/ (4 files)
/usr/local/Cellar/autoconf/2.69/share/man/ (9 files)
I don't think homebrew is using autoconf for itself (keg-only?), because doing brew upgrade autoconf gave me Error: autoconf-2.69 already installed.
However, when I run autoconf, it claims that it's only version 2.61:
$ autoconf --version
autoconf (GNU Autoconf) 2.61
My $PATH:
/Users/agrimm/.rbenv/shims:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin:/usr/local/git/bin
My uname:
$ uname -a
Darwin [redacted] 11.4.2 Darwin Kernel Version 11.4.2: Thu Aug 23 16:25:48 PDT 2012; root:xnu-1699.32.7~1/RELEASE_X86_64 x86_64
How do I fix the error in installing 2.2.0-dev?
Does ruby-build use its own autoconf, or does it only use whatever is available to the user? If so, what is the recommended way to make autoconf 2.67 or higher available to ruby-build?

brew link --overwrite autoconf will make rbenv use homebrew autoconf version.

Related

Unable to Install python 3.6.8 using pyenv on mac Monterey 12.5.1

I'm trying to install python 3.6.8 using pyenv on mac Monterey 12.5.1 but encountering below error
python-build: use openssl#1.1 from homebrew
python-build: use readline from homebrew
Installing Python-3.6.8...
patching file Misc/NEWS.d/next/macOS/2020-06-24-13-51-57.bpo-41100.mcHdc5.rst
patching file configure
Hunk #1 succeeded at 3375 (offset -51 lines).
patching file configure.ac
Hunk #1 succeeded at 495 (offset -15 lines).
python-build: use readline from homebrew
python-build: use zlib from xcode sdk
BUILD FAILED (OS X 12.5.1 using python-build 20180424)
Inspect or clean up the working tree at /var/folders/7h/p55vm3356_jg4jns3n8vngzm0000gp/T/python-build.20220823112323.4068
Results logged to /var/folders/7h/p55vm3356_jg4jns3n8vngzm0000gp/T/python-build.20220823112323.4068.log
Last 10 log lines:
checking for --with-cxx-main=<compiler>... no
checking for clang++... no
configure:
By default, distutils will build C++ extension modules with "clang++".
If this is not intended, then set CXX on the configure command line.
checking for the platform triplet based on compiler characteristics... darwin
configure: error: internal configure error for the platform triplet, please file a bug report
make: *** No targets specified and no makefile found. Stop.
I have tried to reinstall pyenv but it does not help
I have also tried
CFLAGS="-I$(brew --prefix openssl)/include -I$(brew --prefix bzip2)/include -I$(brew --prefix readline)/include -I$(xcrun --show-sdk-path)/usr/include"
LDFLAGS="-L$(brew --prefix openssl)/lib -L$(brew --prefix readline)/lib -L$(brew --prefix zlib)/lib -L$(brew --prefix bzip2)/lib"
pyenv install --patch 3.6.8 < <(curl -sSL https://github.com/python/cpython/commit/8ea6353.patch\?full_index\=1)```
I had similar problem and doing installation by steps from this post helped me. Before following these steps, you better to uninstall all python versions you currently have and pyenv, homebrew.

brew install gcc49 on OS X 10.10 (Unable to find a usable ISL)

When I try to install gcc49, I receive an error
$ brew install https://raw.githubusercontent.com/Homebrew/homebrew-versions/master/gcc49.rb
######################################################################## 100.0%
==> Downloading http://ftpmirror.gnu.org/gcc/gcc-4.9.3/gcc-4.9.3.tar.bz2
Already downloaded: /Library/Caches/Homebrew/gcc49-4.9.3.tar.bz2
==> ../configure --build=x86_64-apple-darwin14.5.0 --prefix=/usr/local/Cellar/gcc49/4.9.3 --libdir=/usr/local/Cellar/gcc49/4.9.3/lib/gcc/4.9 --enable-languages=c,c++,objc,obj-c++ --program-suffix=-4.9 --w
checking for version 0.10 of ISL... no
checking for version 0.11 of ISL... no
checking for version 0.12 of ISL... no
checking for version 0.14 of ISL... no
configure: error: Unable to find a usable ISL. See config.log for details.
Warning: It appears you have MacPorts or Fink installed.
Software installed with other package managers causes known problems for
Homebrew. If a formula fails to build, uninstall MacPorts/Fink and try again.
READ THIS: https://git.io/brew-troubleshooting
However, I do have ISL:
$ brew info isl
isl: stable 0.14.1 (bottled), HEAD
Integer Set Library for the polyhedral model
http://freecode.com/projects/isl
/usr/local/Cellar/isl/0.14.1 (68 files, 3.2M) *
Poured from bottle
From: https://github.com/Homebrew/homebrew/blob/master/Library/Formula/isl.rb
==> Dependencies
Build: xz ✔
Required: gmp ✔
I do not know where is the config.log located.
The correct way to install GCC 4.9 is to use
$ brew install homebrew/versions/gcc49
This way Homebrew will correctly resolve the missing dependencies and install them for you. You can find this version of gcc (or any other) using
$ brew search gcc49
homebrew/versions/gcc49
or
$ brew search gcc
gcc homebrew/versions/gcc47
homebrew/dupes/apple-gcc42 homebrew/versions/gcc48
homebrew/versions/gcc43 homebrew/versions/gcc49
homebrew/versions/gcc44 homebrew/versions/gcc5
homebrew/versions/gcc45 homebrew/versions/llvm-gcc28
homebrew/versions/gcc46
However, the dependency you are missing is not isl but isl011. You can install it with
$ brew install isl011
We can see that this is a dependency of gcc49 with
$ brew info gcc49
==> Dependencies
Required: gmp4 ✔, libmpc08 ✔, mpfr2 ✔, cloog018 ✔, isl011 ✔
The problem is caused by updated Xcode. Need run : "$ xcode-select --install"

brew install gcc46 fails with Clang/xcrun error

I'm trying to use RVM to install ruby 1.9.2 and 1.9.3. It fails because one of the dependencies seems to be gcc46, and rvm uses brew to install it.
rbanerjee:~ $ sudo brew install gcc46
==> Installing dependencies for gcc46: gmp4, mpfr2, libmpc08, ppl011, cloog-ppl015
==> Installing gcc46 dependency: gmp4
==> Downloading ftp://ftp.gmplib.org/pub/gmp-4.3.2/gmp-4.3.2.tar.bz2
Already downloaded: /Library/Caches/Homebrew/gmp4-4.3.2.tar.bz2
==> Patching
==> ./configure --prefix=/usr/local/Cellar/gmp4/4.3.2 --enable-cxx --build=x86_64-apple-darwin
checking ABI=64
checking compiler clang ... no
checking ABI=32
checking compiler clang ... no
configure: error: could not find a working compiler, see config.log for details
but clang is there and working:
rbanerjee:~ $ which clang
/usr/bin/clang
rbanerjee:~ $ clang -v
Apple LLVM version 4.2 (clang-425.0.28) (based on LLVM 3.2svn)
Target: x86_64-apple-darwin11.4.2
Thread model: posix
Weird that the version is 4.2, since I have Xcode 4.6.3 and command line tools 4.6.3 installed. xcrun seems to be a problem too. Digging through the gcc46 logs leads to a failure to install gmp4:
in ~/Library/Logs/Homebrew/gmp4/config.log
/usr/local/Library/ENV/4.3/clang:338:in `exec': No such file or directory - xcrun (Errno::ENOENT)
from /usr/local/Library/ENV/4.3/clang:338
Any ideas? Thanks in advance. OSX Lion. Here's all my system info:
https://gist.github.com/anonymous/9e2cdb6c0d0ca0b29eba

Cannot install gcc48 with homebrew

I cannot install gcc48 with homebrew. The install fails with
(starting from the last lines in configures output):
checking for version 0.10 of ISL... no
checking for version 0.11 of ISL... no
configure: error: Unable to find a usable ISL. See config.log for details.
==> Formula
Tap: homebrew/versions
Path: /usr/local/Library/Taps/homebrew-versions/gcc48.rb
==> Configuration
HOMEBREW_VERSION: 0.9.4
HEAD: e2b10438666f41366f596fe762b2455f5761bcd8
CPU: 8-core 64-bit sandybridge
OS X: 10.8.4-x86_64
Xcode: 4.6.3
CLT: 4.6.0.0.1.1365549073
X11: 2.7.4 => /opt/X11
==> ENV
HOMEBREW_CC: clang
MAKEFLAGS: -j1
CMAKE_PREFIX_PATH: /usr/local
CMAKE_INCLUDE_PATH: /opt/X11/include/freetype2:/usr/include/libxml2:/opt/X11/include
CMAKE_LIBRARY_PATH: /opt/X11/lib
PKG_CONFIG_PATH: /usr/local/opt/isl/lib/pkgconfig:/usr/local/opt/cloog/lib/pkgconfig
PKG_CONFIG_LIBDIR: /usr/lib/pkgconfig:/usr/local/Library/ENV/pkgconfig/10.8:/opt/X11/lib/pkgconfig:/opt/X11/share/pkgconfig
HOMEBREW_MAKE_JOBS: 1
ACLOCAL_PATH: /usr/local/share/aclocal:/opt/X11/share/aclocal
OBJC: cc
PATH: /usr/local/Library/ENV/4.3:/usr/local/opt/cloog/bin:/opt/X11/bin:/usr/bin:/bin:/usr/sbin:/sbin
Error: gcc48 did not build
I do have isl installed.
: brew info isl
isl: stable 0.12, HEAD
http://www.kotnet.org/~skimo/isl/
/usr/local/Cellar/isl/0.12 (55 files, 3.2M) *
Built from source
From: https://github.com/mxcl/homebrew/commits/master/Library/Formula/isl.rb
==> Dependencies
Required: gmp
GCC has imposed a strict requirement about ISL version. At the time being both 4.8 branch and trunk (4.9) requires ISL 0.10 or 0.11. Homebrew has temporarily reverted ISL to 0.11.2 so it should be fine now.
This isn't restricted to Homebrew. There's a problem with the configure script if cloog-0.18.0 uses the bundled sub-package of isl-0.11.1. The VERSION string is not correctly substituted, and is set to "UNKNOWN" in the isl_version() function call - the value that the gcc configure script is testing.
You might have to build (or install) ISL first, and then add --with-isl-prefix=$SOME_DIR to the cloog configure options, so it uses the external ISL installation. I built gcc-4.8.1 for AVR recently from source, and used:
## isl-0.11.1 # ftp://gcc.gnu.org/pub/gcc/infrastructure/
> ../configure --prefix=$CROSSDIR --with-gmp-prefix=$CROSSDIR
> make [check]; make install; rehash
and now build cloog-0.18.0 with the installed 'system' ISL:
> ../configure --prefix=$CROSSDIR --with-isl-prefix=$CROSSDIR \
--with-gmp-prefix=$CROSSDIR
> make [check]; make install; rehash
This also required adding: --with-isl=$CROSSDIR to the gcc configure options.

How can I upgrade to Autoconf 2.6.2 or higher on Mac OS X 10.6?

My environment is Mac OS X 10.6. I have installed Autoconfig using MacPorts:
sudo port -v selfupdate
sudo port install autoconf
But the autoconf installed is 2.6.1.
My question is how can I upgrade it to 2.6.2?
The program I am trying to compile need autoconf 2.6.2
configure.ac:14: error: Autoconf version 2.62 or higher is required
/opt/local/share/aclocal-1.11/init.m4:110: AM_INIT_AUTOMAKE is expanded from...
configure.ac:14: the top level
autom4te: /Developer/usr/bin/gm4 failed with exit status: 63
aclocal-1.11: autom4te failed with exit status: 63
make[1]: *** [libmpeg2] Error 63
I usually do not bother installing any of the autotools on the system, but install them in $HOME instead. Just grab the autoconf tarball from http://ftp.gnu.org/gnu/autoconf/, unpack it and run:
./configure --prefix=$HOME
make
make install
Make sure $HOME/bin is in your PATH before the system dir, or uninstall autoconf from the system.

Resources