[R-SIG-Mac] building R for 64-bit Intel (Mac pro) with working readline and X11?

David Reiss dreiss.isb at gmail.com
Fri Feb 23 23:32:15 CET 2007

I have been able to get R to compile for my Mac Pro using the
excellent directions and resources at http://r.research.att.com/exp/.

However, even after downloading and installing the 64-bit version of
the readline libs, if I turn on the readline option, I cannot get the
configure script to detect that readline is installed! This is the
error I keep getting:

checking for readline/readline.h... yes
checking for rl_callback_read_char in -lreadline... no
checking for main in -lncurses... yes
checking for rl_callback_read_char in -lreadline... no
checking for history_truncate_file... no
configure: error: --with-readline=yes (default) and headers/libs are
not available

I am sure that "rl_callback_read_char" exists in the include files.

Another problem is that I downloaded and installed the 64-bit X11
libraries as suggested and compiled fine (without readline) but upon
typing "x11()" in the newly-compiled R, I get this error:

Error in x11() : X11 module cannot be loaded
In addition: Warning message:
unable to load shared library
6): Symbol not found: _XtStrings
  Referenced from:
  Expected in: dynamic lookup

I have made sure that the 64-bit libraries are first in my
LD_LIBRARY_PATH, but this doesnt help.

Here is the configure command I am using:

> ./configure CC='gcc -arch x86_64' CXX='g++ -arch x86_64' F77='gfortran -arch x86_64' FC='gfortran -arch x86_64' --with-blas='-framework vecLib' --with-lapack CPPFLAGS='-I/sw/include -I/sw/include/readline -I/usr/local/include -I/usr/local/include/readline' LDFLAGS='-L/sw/lib -L/usr/local/lib/x86_64 -L/usr/local/lib' r_arch=x86_64 --with-system-zlib --build=x86_64-apple-darwin8.8.1 --prefix=/usr/local/lib64 --with-x --x-includes=/usr/local/lib64/X11/include/ --x-libraries=/usr/local/lib64/X11/lib/ --with-readline

Can anyone help me with either of these 2 issues?
thanks very much.

David J. Reiss
Senior Research Scientist, Computational Biology
Institute for Systems Biology
dreiss at systemsbiology.org

More information about the R-SIG-Mac mailing list