This question is about compiling R-1.6.2 from source on a
Sparcstation-20 machine running Solaris 7, gcc-2.95.3 and
readline-4.2 (both gcc and readline from sunfreeware.com).
I searched the r-help archive and the FAQ. The errors seem to be
related to the binary readline libraries, and I have
/usr/local/lib/libreadline.a,libreadline.so@, and
libreadline.so.4.
The attached errors are from config.log. ./configure finds
readline header files in /usr/local/include/readline. I can make
and install R, but command line editing and savehistory() do not
work.
Suggestions are appreciated.
Yuelin Li.
--------
configure:11366: checking for rl_callback_read_char in -lreadline
configure:11397: gcc -o conftest -g -O2 -I/usr/local/include
-L/usr/local/lib conftest.c -lreadline -ldl -lncurses -lm >&5
ld: fatal: symbol `_init' is multiply-defined:
(file
/usr/local/lib/gcc-lib/sparc-sun-solaris2.7/2.95.3/crti.o and
file /usr/local/lib/libreadline.so);
ld: fatal: symbol `_start' is multiply-defined:
(file
/usr/local/lib/gcc-lib/sparc-sun-solaris2.7/2.95.3/crt1.o and
file /usr/local/lib/libreadline.so);
ld: fatal: symbol `_fini' is multiply-defined:
(file
/usr/local/lib/gcc-lib/sparc-sun-solaris2.7/2.95.3/crti.o and
file /usr/local/lib/libreadline.so);
ld: fatal: symbol `_lib_version' is multiply-defined:
(file /usr/ccs/lib/values-Xa.o and file
/usr/local/lib/libreadline.so);
ld: fatal: File processing errors. No output written to conftest
collect2: ld returned 1 exit status
configure:11400: $? = 1
configure: failed program was:
| #line 11373 "configure"
| /* confdefs.h. */
|
| #define PACKAGE_NAME "R"
| #define PACKAGE_TARNAME "r"| #define PACKAGE_VERSION
"1.6.2"
| #define PACKAGE_STRING "R 1.6.2"
| #define PACKAGE_BUGREPORT "r-bugs at R-project.org"
| #define PACKAGE "R"
| #define VERSION "1.6.2"
| #define R_PLATFORM "sparc-sun-solaris2.7"
| #define R_CPU "sparc"
| #define R_VENDOR "sun"
| #define R_OS "solaris2.7"
| #define Unix 1
| #define STDC_HEADERS 1
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRING_H 1
| #define HAVE_MEMORY_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_UNISTD_H 1
| #define HAVE_DLFCN_H 1
| #define HAVE_LIBM 1
| #define HAVE_LIBNCURSES 1
| #define HAVE_LIBDL 1
| /* end confdefs.h. */
|
| /* Override any gcc2 internal prototype to avoid an error. */
| #ifdef __cplusplus
| extern "C"
| #endif
| /* We use char because int might match the return type of a
gcc2
| builtin and then its argument prototype would still apply.
*/
| char rl_callback_read_char ();
| int
| main ()
| {
| rl_callback_read_char ();
| ;
| return 0;
| }
On Wed, 12 Feb 2003, Yuelin Li wrote:> This question is about compiling R-1.6.2 from source on a > Sparcstation-20 machine running Solaris 7, gcc-2.95.3 and > readline-4.2 (both gcc and readline from sunfreeware.com).This is not an R question, but one for the maintainers of sunfreeware.com. There is no problem with those tools if compiled from the sources (although they are rather old versions).> I searched the r-help archive and the FAQ. The errors seem to be > related to the binary readline libraries, and I have > /usr/local/lib/libreadline.a,libreadline.so@, and > libreadline.so.4. > > The attached errors are from config.log. ./configure finds > readline header files in /usr/local/include/readline. I can make > and install R, but command line editing and savehistory() do not > work. > > Suggestions are appreciated.Compile libreadline yourself?> > Yuelin Li. > > -------- > configure:11366: checking for rl_callback_read_char in -lreadline > configure:11397: gcc -o conftest -g -O2 -I/usr/local/include > -L/usr/local/lib conftest.c -lreadline -ldl -lncurses -lm >&5 > ld: fatal: symbol `_init' is multiply-defined: > (file > /usr/local/lib/gcc-lib/sparc-sun-solaris2.7/2.95.3/crti.o and > file /usr/local/lib/libreadline.so); > ld: fatal: symbol `_start' is multiply-defined: > (file > /usr/local/lib/gcc-lib/sparc-sun-solaris2.7/2.95.3/crt1.o and > file /usr/local/lib/libreadline.so); > ld: fatal: symbol `_fini' is multiply-defined: > (file > /usr/local/lib/gcc-lib/sparc-sun-solaris2.7/2.95.3/crti.o and > file /usr/local/lib/libreadline.so); > ld: fatal: symbol `_lib_version' is multiply-defined: > (file /usr/ccs/lib/values-Xa.o and file > /usr/local/lib/libreadline.so);-- Brian D. Ripley, ripley at stats.ox.ac.uk Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272866 (PA) Oxford OX1 3TG, UK Fax: +44 1865 272595
Yuelin Li <yuelin at mail.med.upenn.edu> writes:> This question is about compiling R-1.6.2 from source on a > Sparcstation-20 machine running Solaris 7, gcc-2.95.3 and > readline-4.2 (both gcc and readline from sunfreeware.com).I had some problems with the sunfreeware readline too when I tried 1.5 years ago. Ended up removing the .so version. -- O__ ---- Peter Dalgaard Blegdamsvej 3 c/ /'_ --- Dept. of Biostatistics 2200 Cph. N (*) \(*) -- University of Copenhagen Denmark Ph: (+45) 35327918 ~~~~~~~~~~ - (p.dalgaard at biostat.ku.dk) FAX: (+45) 35327907