Compiling R under Caldera Open Linux 2.2 (PR#268)
Mon, 6 Sep 1999 22:03:53 +0200 (MET DST)
Thanks for your help. I loaded XFree86-devel-126.96.36.199-3.i386.rpm from my
OpenLinux CD and as you indicate this solved by X11 include file
I then encountered the linking same problem as you describe below. The
error message is saying that the compiler can't find the libg2c library,
which is its runtime library. Apparently the g77 supplied by Caldera is
missing this important piece. I downloaded egcs-1.1.2-12.i386.rpm from
the Red Hat web site, then did the following to extract and install
1) rpm2cpio < egcs-1.1.2-12.i386.rpm > egcs-1.1.2-12.cpio
2) cpio -irv \*libg2c.a < egcs-1.1.2-12.cpio
- when prompted to rename it, I entered libg2c.a. This created the
libg2c archive in my current directory.
3) mv libg2c.a /usr/lib/gcc-lib/i386-linux/egcs-2.91.66
That got past the link error you describe. I then encountered a whole
series of undefined references to X routines. I was able to determine
that all the routines exist in the X11 library
/usr/X11R6/lib/libX11.so.6.1 but configure was not setting things up
properly to link that library. After spending a while trying to figure
out configure (it's pretty confusing besides not handling X well; for
instance --with-x doesn't do anything, and --x-libraries doesn't seem to
do much) I gave up and editted the R-0.64.2/src/main/Makefile directly.
I added on line 44 "-L /usr/X11R6/lib" before $(DLLFLAGS) and also -lX11
at the end of the line. After doing that, "make" and "make install"
both completed successfully.
So now I've got R installed successfully. Its interface is fairly
intimidating. Are there some examples online that would walk me through
some simple calculations/graphs?
- Jack Fenner
John Maindonald wrote:
> To: firstname.lastname@example.org
> Subject: Compilation of R under Caldera OpenLinux 2.2
> > On Sat, 28 Aug 1999 email@example.com wrote:
> > >
> > > I am attempting to compile R-0.64.2 under Caldera OpenLinux 2.2. I have
> > > KDE installed but not gnome. When I ran configure, it correctly
> > > indicated that gnome is not installed. However when I then ran make, I
> > > received errors complaining that the include file X11/X.h and similar
> > > are not found.
> > However, you do have X11 on your machine if you have KDE, and you
> > definitely do want to use X11 in R to get graphics.
> > You may not have the X11 header files installed -- they should be
> > somewhere under /usr/X11 or /usr/include/X11. If the header files aren't
> > installed then you will need to install them. They will be on your
> > distribution CD, perhaps in a package called something like x-devel.
> They are in the file Packages/RPMS/XFree86-devel-188.8.131.52-4.i386.rpm
> (On the RedHat 6.0 distribution, there is
> which seems to be a later version.)
> I have been wrestling with this also. I had to install g77 from
> the distribution CD, then the above rpm.
> Having got this in order, I then received extensive output,
> terminated by the following (which I have formatted on to
> multiple lines):
> gcc -export-dynamic -o ../../bin/R.X11 arithmetic.o array.o attrib.o
> bind.o builtin.o character.o coerce.o colors.o complex.o context.o
> cov.o cum.o debug.o devPS.o devPicTeX.o deparse.o deriv.o devices.o
> dotcode.o dstruct.o duplicate.o envir.o errors.o eval.o format.o
> fourier.o gram.o gram-ex.o graphics.o iosupport.o list.o logic.o
> main.o match.o memory.o model.o names.o objects.o optimize.o
> options.o par.o paste.o platform.o plot.o plot3d.o plotmath.o
> print.o printarray.o printvector.o printutils.o random.o relop.o
> saveload.o scan.o seq.o sort.o source.o split.o subassign.o
> subscript.o subset.o summary.o unique.o util.o version.o
> ../unix/libunix.a ../appl/libappl.a ../nmath/libmath.a -lSM -lICE
> -L/usr/X11R6/lib -lX11 -L/usr/lib/gcc-lib/i386-linux/egcs-2.91.66
> -L/usr/i386-linux/lib -lg2c -lm -lg2c: -ldl -lm
> /usr/i386-linux/bin/ld: cannot open -lg2c: No such file or directory
> make: *** [../../bin/R.X11] Error 1 make: Leaving directory
> `/home/john/BUILD/src/main' make: *** [R] Error 2 make:
> Leaving directory `/home/john/BUILD/src/main' make: *** [R] Error
> 1 make: Leaving directory `/home/john/BUILD/src' make: *** [R]
> Error 1
> I have been unable to find anything on the distribution CD that
> might answer to the lg2c. Any clues would be welcome.
> These difficulties aside, the Caldera OpenLinux 2.2 distribution
> is much more novice-friendly than RedHat 6.0. Configuration is
> much quicker and more straightforward.
> John Maindonald email : firstname.lastname@example.org
> Statistical Consulting Unit, phone : (6249)3998
> c/o CMA, SMS, fax : (6249)5549
> John Dedman Mathematical Sciences Building
> Australian National University
> Canberra ACT 0200
I am life that wills to live in the midst of life that wills to live.
- Albert Schweitzer, "Out of my Life and Thought"
r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: email@example.com