[R] R-2.3.0 make error

Prof Brian Ripley ripley at stats.ox.ac.uk
Tue May 2 10:06:55 CEST 2006


When I compile cmpxblas.f under gfortran, I do not get a dependence on 
z_abs, but I do when I compile it under g77.

So I think a mixture of compilers has been used here.  z_abs is an entry 
point in -lg2c not -lgfortran ....


On Mon, 1 May 2006, Peter Dalgaard wrote:

> "Wuming Gong" <wuming.gong at gmail.com> writes:
>
>> Dear list,
>>
>> When compiling the R-2.3.0 on FC4 x86_64, I got the following errors:
>>
>> make[3]: Entering directory
>> `/project/scratch3/ligroup/wuming/src/R-2.3.0/src/main'
>> gcc -Wl,--export-dynamic -L/usr/local/lib64 -o R.bin Rmain.o
>> CConverters.o CommandLineArgs.o Rdynload.o Renviron.o RNG.o apply.o
>> arithmetic.o apse.o array.o attrib.o base.o bind.o builtin.o
>> character.o coerce.o colors.o complex.o connections.o context.o cov.o
>> cum.o dcf.o datetime.o debug.o deparse.o deriv.o dotcode.o dounzip.o
>> dstruct.o duplicate.o engine.o envir.o errors.o eval.o format.o
>> fourier.o gevents.o gram.o gram-ex.o graphics.o identical.o internet.o
>> iosupport.o lapack.o list.o localecharset.o logic.o main.o mapply.o
>> match.o memory.o model.o names.o objects.o optim.o optimize.o
>> options.o par.o paste.o pcre.o platform.o plot.o plot3d.o plotmath.o
>> print.o printarray.o printvector.o printutils.o qsort.o random.o
>> regex.o registration.o relop.o rlocale.o saveload.o scan.o seq.o
>> serialize.o size.o sort.o source.o split.o sprintf.o startup.o
>> subassign.o subscript.o subset.o summary.o sysutils.o unique.o util.o
>> version.o vfonts.o xxxpr.o   ../unix/libunix.a ../appl/libappl.a
>> ../nmath/libnmath.a  -lgfortran -lm -lgcc_s  ../extra/zlib/libz.a
>> ../extra/bzip2/libbz2.a ../extra/pcre/libpcre.a  -lreadline -lncurses
>> -ldl -lm
>> ../appl/libappl.a(cmplxblas.o)(.text+0x1100a): In function `zrotg_':
>> /project/scratch3/ligroup/wuming/src/R-2.3.0/src/appl/cmplxblas.f:5579:
>> undefined reference to `z_abs'
>> ../appl/libappl.a(cmplxblas.o)(.text+0x11069):/project/scratch3/ligroup/wuming/src/R-2.3.0/src/appl/cmplxblas.f:5585:
>> undefined reference to `z_abs'
>> ../appl/libappl.a(cmplxblas.o)(.text+0x11079):/project/scratch3/ligroup/wuming/src/R-2.3.0/src/appl/cmplxblas.f:5585:
>> undefined reference to `z_abs'
>> ../appl/libappl.a(cmplxblas.o)(.text+0x110de):/project/scratch3/ligroup/wuming/src/R-2.3.0/src/appl/cmplxblas.f:5586:
>> undefined reference to `z_abs'
>> ../appl/libappl.a(cmplxblas.o)(.text+0x11146):/project/scratch3/ligroup/wuming/src/R-2.3.0/src/appl/cmplxblas.f:5586:
>> undefined reference to `z_abs'
>> ../appl/libappl.a(cmplxblas.o)(.text+0x1116e):/project/scratch3/ligroup/wuming/src/R-2.3.0/src/appl/cmplxblas.f:5588:
>> more undefined references to `z_abs' follow
>> collect2: ld returned 1 exit status
>> make[3]: *** [R.bin] Error 1
>> make[3]: Leaving directory
>> `/project/scratch3/ligroup/wuming/src/R-2.3.0/src/main'
>> make[2]: *** [R] Error 2
>> make[2]: Leaving directory
>> `/project/scratch3/ligroup/wuming/src/R-2.3.0/src/main'
>> make[1]: *** [R] Error 1
>> make[1]: Leaving directory `/project/scratch3/ligroup/wuming/src/R-2.3.0/src'
>> make: *** [R] Error 1
>>
>> Is there any way to fix this problem?
>
> Hmm... It's not happening to me on a similar setup
>
> $ uname -a
> Linux janus 2.6.16-1.2096_FC4smp #1 SMP Wed Apr 19 16:01:54 EDT 2006
> x86_64 x86_64 x86_64 GNU/Linux
>
> gcc -Wl,--export-dynamic -L/usr/local/lib64 -o R.bin Rmain.o
> CConverters.o CommandLineArgs.o Rdynload.o Renviron.o RNG.o apply.o
> arithmetic.o apse.o array.o attrib.o base.o bind.o builtin.o
> character.o coerce.o colors.o complex.o connections.o context.o cov.o
> cum.o dcf.o datetime.o debug.o deparse.o deriv.o dotcode.o dounzip.o
> dstruct.o duplicate.o engine.o envir.o errors.o eval.o format.o
> fourier.o gevents.o gram.o gram-ex.o graphics.o identical.o internet.o
> iosupport.o lapack.o list.o localecharset.o logic.o main.o mapply.o
> match.o memory.o model.o names.o objects.o optim.o optimize.o
> options.o par.o paste.o pcre.o platform.o plot.o plot3d.o plotmath.o
> print.o printarray.o printvector.o printutils.o qsort.o random.o
> regex.o registration.o relop.o rlocale.o saveload.o scan.o seq.o
> serialize.o size.o sort.o source.o split.o sprintf.o startup.o
> subassign.o subscript.o subset.o summary.o sysutils.o unique.o util.o
> version.o vfonts.o xxxpr.o   ../unix/libunix.a ../appl/libappl.a
> ../nmath/libnmath.a -lblas -lgfortran -lm -lgcc_s
> ../extra/zlib/libz.a ../extra/bzip2/libbz2.a ../extra/pcre/libpcre.a
> -lreadline -lncurses  -ldl -lm
>
> Apparently, you are configuring without a BLAS library, but it is not
> like I get into trouble by removing them from my setup. I'm puzzled.
>
> You might check whether you need to upgrade something in your system.
>
>
>

-- 
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




More information about the R-help mailing list