[R] Compiling Matrix on Solaris 10 x86-64 Sun Studio 12

Prof Brian Ripley ripley at stats.ox.ac.uk
Thu Feb 12 08:12:44 CET 2009

This is a known issue.  Fixes have been passed to the Matrix authors, 
so please wait for an update.

If that is not possible, try an older version of Matrix from the CRAN 
archive: I think -15 is the latest without the problematic code.

(At http://cran.r-project.org/src/contrib/Archive/Matrix/, BTW)

On Wed, 11 Feb 2009, Dongseok Choi wrote:

> Hi all,
> I have trouble to compile Matrix packages on Solar10 x86-64 with Sun compilers.
> I saw some postings on this but am not sure how to solve this problem.
> It is becoming critical as I cannot install biocLite() because of its dependency on Matrix.
> Could you direct me how to resolve the issue?
> Thanks in advance!
> Dongseok
> R version 2.8.1 (2008-12-22)
> Copyright (C) 2008 The R Foundation for Statistical Computing
> ISBN 3-900051-07-0
> R is free software and comes with ABSOLUTELY NO WARRANTY.
> You are welcome to redistribute it under certain conditions.
> Type 'license()' or 'licence()' for distribution details.
> R is a collaborative project with many contributors.
> Type 'contributors()' for more information and
> 'citation()' on how to cite R or R packages in publications.
> Type 'demo()' for some demos, 'help()' for on-line help, or
> 'help.start()' for an HTML browser interface to help.
> Type 'q()' to quit R.
>> install.packages("Matrix")
> --- Please select a CRAN mirror for use in this session ---
> trying URL 'http://cran.fhcrc.org/src/contrib/Matrix_0.999375-20.tar.gz'
> Content type 'application/x-gzip' length 1954872 bytes (1.9 Mb)
> opened URL
> ==================================================
> downloaded 1.9 Mb
> * Installing *source* package 'Matrix' ...
> ** libs
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c CHMfactor.c -o CHMfactor.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c Csparse.c -o Csparse.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c TMatrix_as.c -o TMatrix_as.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c Tsparse.c -o Tsparse.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c init.c -o init.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c Mutils.c -o Mutils.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c chm_common.c -o chm_common.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c cs.c -o cs.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c cs_utils.c -o cs_utils.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c dense.c -o dense.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c dgCMatrix.c -o dgCMatrix.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c dgTMatrix.c -o dgTMatrix.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c dgeMatrix.c -o dgeMatrix.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c dpoMatrix.c -o dpoMatrix.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c dppMatrix.c -o dppMatrix.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c dsCMatrix.c -o dsCMatrix.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c dsyMatrix.c -o dsyMatrix.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c dspMatrix.c -o dspMatrix.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c dtCMatrix.c -o dtCMatrix.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c dtTMatrix.c -o dtTMatrix.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c dtrMatrix.c -o dtrMatrix.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c dtpMatrix.c -o dtpMatrix.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c factorizations.c -o factorizations.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c ldense.c -o ldense.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c lgCMatrix.c -o lgCMatrix.o
> cc -m64 -I/home/choid/bin/R281/lib/R/include -I./UFconfig -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include -c sparseQR.c -o sparseQR.o
> ( cd Lib ; make clean )
> ( cd Lib ; make clean )
> ( cd Source ; make clean )
> ( cd Source ; make clean )
> ( cd Lib ; make lib )
> CC -m64 -I/home/choid/bin/R281/lib/R/include -I../../UFconfig -I../../CHOLMOD/Include -I../Include -DNPARTITION -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include  -c ../Source/spqr_rmap.cpp
> CC -m64 -I/home/choid/bin/R281/lib/R/include -I../../UFconfig -I../../CHOLMOD/Include -I../Include -DNPARTITION -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include  -c ../Source/SuiteSparseQR_C.cpp
> CC -m64 -I/home/choid/bin/R281/lib/R/include -I../../UFconfig -I../../CHOLMOD/Include -I../Include -DNPARTITION -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include  -c ../Source/SuiteSparseQR_expert.cpp
> CC -m64 -I/home/choid/bin/R281/lib/R/include -I../../UFconfig -I../../CHOLMOD/Include -I../Include -DNPARTITION -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include  -c ../Source/spqr_parallel.cpp
> CC -m64 -I/home/choid/bin/R281/lib/R/include -I../../UFconfig -I../../CHOLMOD/Include -I../Include -DNPARTITION -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include  -c ../Source/spqr_kernel.cpp
> CC -m64 -I/home/choid/bin/R281/lib/R/include -I../../UFconfig -I../../CHOLMOD/Include -I../Include -DNPARTITION -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include  -c ../Source/spqr_analyze.cpp
> CC -m64 -I/home/choid/bin/R281/lib/R/include -I../../UFconfig -I../../CHOLMOD/Include -I../Include -DNPARTITION -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include  -c ../Source/spqr_assemble.cpp
> CC -m64 -I/home/choid/bin/R281/lib/R/include -I../../UFconfig -I../../CHOLMOD/Include -I../Include -DNPARTITION -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include  -c ../Source/spqr_cpack.cpp
> CC -m64 -I/home/choid/bin/R281/lib/R/include -I../../UFconfig -I../../CHOLMOD/Include -I../Include -DNPARTITION -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include  -c ../Source/spqr_csize.cpp
> CC -m64 -I/home/choid/bin/R281/lib/R/include -I../../UFconfig -I../../CHOLMOD/Include -I../Include -DNPARTITION -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include  -c ../Source/spqr_fcsize.cpp
> CC -m64 -I/home/choid/bin/R281/lib/R/include -I../../UFconfig -I../../CHOLMOD/Include -I../Include -DNPARTITION -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include  -c ../Source/spqr_debug.cpp
> CC -m64 -I/home/choid/bin/R281/lib/R/include -I../../UFconfig -I../../CHOLMOD/Include -I../Include -DNPARTITION -I/usr/local/include -I/opt/SUNWspro/prod/include -I/usr/include -I/usr/sfw/include    -KPIC  -O -I/opt/SUNWspro/prod/include  -c ../Source/spqr_front.cpp
> "../Source/spqr_front.cpp", line 184: Error: Could not find a match for larfg needed in house<double>(int, double*, cholmod_common_struct*).
> "../Source/spqr_front.cpp", line 413:     Where: While instantiating "house<double>(int, double*, cholmod_common_struct*)".
> "../Source/spqr_front.cpp", line 413:     Where: Instantiated from spqr_front<double>(int, int, int, double, int, int, double*, int*, char*, double*, double*, cholmod_common_struct*).
> "../Source/spqr_front.cpp", line 564:     Where: Instantiated from non-template code.
> 1 Error(s) detected.
> *** Error code 1
> make: Fatal error: Command failed for target `spqr_front.o'
> Current working directory /tmp/R.INSTALL.KwaqDb/Matrix/src/SPQR/Lib
> *** Error code 1
> make: Fatal error: Command failed for target `library'
> Current working directory /tmp/R.INSTALL.KwaqDb/Matrix/src/SPQR
> *** Error code 1
> The following command caused the error:
> for d in SPQR CHOLMOD COLAMD AMD; do \
>  (cd ${d} && CFLAGS="-O -I/opt/SUNWspro/prod/include" CXXFLAGS="-O -I/opt/SUNWspro/prod/include" MkInclude="/home/choid/bin/R281/lib/R/etc/Makeconf" make library) || exit 1; \
> done
> make: Fatal error: Command failed for target `sublibs'
> ERROR: compilation failed for package 'Matrix'
> ** Removing '/home/choid/bin/R281/lib/R/library/Matrix'
> The downloaded packages are in
>        /tmp/RtmpjvNsHB/downloaded_packages
> Updating HTML index of packages in '.Library'
> Warning message:
> In install.packages("Matrix") :
>  installation of package 'Matrix' had non-zero exit status
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.

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