Failure to load the recommended package Matrix (Was: [R] Can one get a list of recommended packages?)

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Failure to load the recommended package Matrix (Was: [R] Can one get a list of recommended packages?)

Douglas Bates-2
On Sun, Jun 13, 2010 at 8:28 AM, Uwe Ligges
<[hidden email]> wrote:

>
>
> On 13.06.2010 01:09, Dr. David Kirkby wrote:
>>
>> On 06/12/10 05:27 PM, Douglas Bates wrote:
>>>
>>> On Sat, Jun 12, 2010 at 8:37 AM, Dr. David Kirkby
>>> <[hidden email]> wrote:
>>>>
>>>> R 2.10.1 is used in the Sage maths project. Several recommended packages
>>>> (Matrix, class, mgcv, nnet, rpart, spatial, and survival) are failing to
>>>> build on Solaris 10 (SPARC).
>>>
>>> Have you checked the dependencies for those packages? Some require GNU
>>> make.
>>
>> We used GNU make.
>>
>>>> We would like to be able to get a list of the recommended packages for R
>>>> 2.10.1, but ideally via a call to R, so it is not necessary to update
>>>> that
>>>> list every time a new version of R is released. We do not want to
>>>> access the
>>>> Internet to get this information.
>>>
>>>> Is there a way in R to list the recommended packages?
>>>
>>> I'm not sure I understand the logic of this. If you are going to
>>> build R then presumably you have the tar.gz file which contains the
>>> sources for the recommended packages in the subdirectory
>>> src/library/Recommended/. Why not get the list from there?
>>
>> The reason is when the version of R gets updated in Sage, then someone
>> will have to check that list again, and more than likely fail to do so,
>> with the result tests will fail since packages do not exist, or worst
>> still we will be unaware they have failed to build properly.
>>
>> Therefore, being able to get them from a command would be useful, but
>> can understand if that is not possible.
>>
>>> $ cd ~/src/R-devel/src/library/Recommended/
>>> $ ls *.tgz
>>> boot.tgz codetools.tgz lattice.tgz mgcv.tgz rpart.tgz
>>> class.tgz foreign.tgz MASS.tgz nlme.tgz spatial.tgz
>>> cluster.tgz KernSmooth.tgz Matrix.tgz nnet.tgz survival.tgz
>>
>> OK, thank you for that list.
>>
>>>> Better still, is there a way to list the recommended packages which
>>>> have not
>>>> been installed, so getting a list of any failures?
>>>
>>> Again, this seems to be a rather convoluted approach. Why not check
>>> why the packages don't install properly?
>>
>> R had built, and the failure of the packages to build was not very
>> obvious, since it did not cause make to exit with a non-zero exit code.
>> Nobody had noticed until very recently that there was a problem.
>>
>> Therefore I proposed to make a test of the packages that should have
>> been installed, and ensure they actually all had.
>>
>> You need to be aware that R is just one part of Sage. Building the whole
>> of Sage takes a long time (>24 hours on some computers) so needless to
>> say, people will not view every line of error messages. The fact that
>> 'make' succeeded left us a false sense of security, when later it was
>> realsed there were problems when R run its self-tests.
>>
>> Dave
>
>
> But if you really want to sense some security, you should really run
> make check-all
> after the installation, particularly since you are on a platform that is not
> really mainstream any more.
>
> Uwe Ligges

And if you look at the other R-help message posted by David Kirby you
will find a link to the trouble ticket report in Sage as
http://trac.sagemath.org/sage_trac/ticket/9201
which, fortunately, contains a link to the compilation log file
http://sage.math.washington.edu/home/mpatel/trac/8306/r-2.10.1.p2.log

The log file correctly points out the problem, which is that the
compiled shared object for the Matrix package can't be loaded because
it contains references to objects in another library from the compiler
and that library is not on the LD_LIBRARY_PATH during the dyn.load
from within R.  So the original poster needs to look at how the
DLLpath is being configured.

Exactly how this ended up as a request to somehow determine a list of
recommended packages on the fly from within R is a wonderful example
of misguided speculation but has nothing whatsoever to do with the
problem.  Even the idea that there are a host of other recommended
packages that failed to compile because they depend on the Matrix
package is pure speculation and, of course, hopelessly wrong.  The
installation of the Matrix package failed because the check on whether
the package could be loaded failed.  The compilation of the
recommended packages stopped at that point.  The other packages
weren't compiled because they came after the Matrix package in the
compilation sequence.

Problems in compilation of R or its recommended packages should be
reported on the R-devel mailing list and I have moved this thread from
R-help to R-devel.

Admittedly it was the original poster of the Sage trouble ticket who
decided that the issue to focus on was missing recommended packages.
That's a red herring.  The issue is the visibility of the some of the
libraries from the gcc toolchain when R is loading a package.

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel
Reply | Threaded
Open this post in threaded view
|

Re: Failure to load the recommended package Matrix (Was: [R] Can one get a list of recommended packages?)

Ei-ji Nakama
> And if you look at the other R-help message posted by David Kirby you
> will find a link to the trouble ticket report in Sage as
> http://trac.sagemath.org/sage_trac/ticket/9201

>From the link,...
|  kirkby@t2:[~] $ echo $LD_LIBRARY_PATH
| /usr/local/gcc-4.4.1-sun-linker/lib:/usr/local/gcc-4.4.1-sun-linker/lib/sparcv9:/usr/local/lib

`/usr/local/gcc-4.4.1-sun-linker/lib/sparcv9' is 64bit, it is unnecessary.
I think that this obstructs it.
--
EI-JI Nakama  <nakama (a) ki.rim.or.jp>
"\u4e2d\u9593\u6804\u6cbb"  <nakama (a) ki.rim.or.jp>

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel
Reply | Threaded
Open this post in threaded view
|

Re: Failure to load the recommended package Matrix (Was: [R] Can one get a list of recommended packages?)

Ei-ji Nakama
Sorry, my  bark up the wrong tree...

When LD_LIBRARY_PATH_32 is set, I think that I become it in such a state.

http://docs.sun.com/app/docs/doc/819-0690/chapter1-11192?a=view#chapter1-9

It is better when there is the following.
crle ; crle -64 ; env|grep "LD_"

2010/6/14 Ei-ji Nakama <[hidden email]>:

>> And if you look at the other R-help message posted by David Kirby you
>> will find a link to the trouble ticket report in Sage as
>> http://trac.sagemath.org/sage_trac/ticket/9201
>
> From the link,...
> |  kirkby@t2:[~] $ echo $LD_
> | /usr/local/gcc-4.4.1-sun-linker/lib:/usr/local/gcc-4.4.1-sun-linker/lib/sparcv9:/usr/local/lib
>
> `/usr/local/gcc-4.4.1-sun-linker/lib/sparcv9' is 64bit, it is unnecessary.
> I think that this obstructs it.
> --
> EI-JI Nakama  <nakama (a) ki.rim.or.jp>
> "\u4e2d\u9593\u6804\u6cbb"  <nakama (a) ki.rim.or.jp>
>



--
EI-JI Nakama  <nakama (a) ki.rim.or.jp>
"\u4e2d\u9593\u6804\u6cbb"  <nakama (a) ki.rim.or.jp>

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel
Reply | Threaded
Open this post in threaded view
|

Re: Failure to load the recommended package Matrix (Was: [R] Can one get a list of recommended packages?)

Dr. David Kirkby
In reply to this post by Ei-ji Nakama
On 06/14/10 10:05 AM, Ei-ji Nakama wrote:

>> And if you look at the other R-help message posted by David Kirby you
>> will find a link to the trouble ticket report in Sage as
>> http://trac.sagemath.org/sage_trac/ticket/9201
>
>> From the link,...
> |  kirkby@t2:[~] $ echo $LD_LIBRARY_PATH
> | /usr/local/gcc-4.4.1-sun-linker/lib:/usr/local/gcc-4.4.1-sun-linker/lib/sparcv9:/usr/local/lib
>
> `/usr/local/gcc-4.4.1-sun-linker/lib/sparcv9' is 64bit, it is unnecessary.
> I think that this obstructs it.

This is not the reason. If it picked up the wrong library, then there would be a
message that there was the wrong ELF class, but no library whatever is being found.

I've tried without the 'sparcv9' in LD_LIBRARY_PATH and it makes no difference
whatsoever. I've tried on two SPARCs too, running different releases of Solaris 10.

Using 'crle' might work, but that is not really a good answer, as it needs root
access. It should be possible to install an application like R without being
root. There is something wrong if LD_LIBRARY_PATH can't be used to locate
libraries.

I can build the whole of the Sage source code (around 300 MB) and don't see this
failure elsewhere. Instead, there are a number of programs which link to
libgcc_s.so.1.

I stuck some further information at

http://trac.sagemath.org/sage_trac/ticket/9201

but it basically just confirms what I've written above.

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel
Reply | Threaded
Open this post in threaded view
|

Re: Failure to load the recommended package Matrix (Was: [R] Can one get a list of recommended packages?)

Ei-ji Nakama
I'm suffering from hay fever now...

from http://sage.math.washington.edu/home/mpatel/trac/8306/r-2.10.1.p2.log
| gcc -v
| Using built-in specs.
| Target: sparc-sun-solaris2.10
| Configured with: ../gcc-4.4.1/configure
--prefix=/usr/local/gcc-4.4.1-sun-linker/ --with-as=/usr/ccs/bin/as
| --without-gnu-as --with-ld=/usr/ccs/bin/ld --without-gnu-ld
--enable-languages=c,c++,fortran --with-
| mpfr-include=/usr/local/include --with-mpfr-lib=/usr/local/lib
--with-gmp-include=/usr/local/include --with-
| gmp-lib=/usr/local/lib CC=/usr/sfw/bin/gcc CXX=/usr/sfw/bin/g++
| Thread model: posix
| gcc version 4.4.1 (GCC)

I think that this gcc is `/usr/local/gcc-4.4.1-sun-linker/bin/gcc'.
library when gcc compiled it is
`/usr/local/gcc-4.4.1-sun-linker/lib/libgcc_s.so'.

if it follows the instruction of FAQ(gcc).
http://gcc.gnu.org/faq.html#rpath

The build is done by using  run time directory in LD_RUN_PATH.
  LD_RUN_PATH=/usr/local/gcc-4.4.1-sun-linker/lib make
      or
You should enumerate the run time directory of gcc in LD_LIBRARY_PATH.
  LD_LIBRARY_PATH=/usr/local/gcc-4.4.1-sun-linker/lib:$LD_LIBRARY_PATH

I think that it is a policy of system administration. It is not a problem of R.
There is not the problem in R on Solaris10 which I use.

Sorry in advance if I'm wrong.

2010/6/15 Dr. David Kirkby <[hidden email]>:

> On 06/14/10 10:05 AM, Ei-ji Nakama wrote:
>>>
>>> And if you look at the other R-help message posted by David Kirby you
>>> will find a link to the trouble ticket report in Sage as
>>> http://trac.sagemath.org/sage_trac/ticket/9201
>>
>>> From the link,...
>>
>> |  kirkby@t2:[~] $ echo $LD_LIBRARY_PATH
>> |
>> /usr/local/gcc-4.4.1-sun-linker/lib:/usr/local/gcc-4.4.1-sun-linker/lib/sparcv9:/usr/local/lib
>>
>> `/usr/local/gcc-4.4.1-sun-linker/lib/sparcv9' is 64bit, it is unnecessary.
>> I think that this obstructs it.
>
> This is not the reason. If it picked up the wrong library, then there would
> be a message that there was the wrong ELF class, but no library whatever is
> being found.
>
> I've tried without the 'sparcv9' in LD_LIBRARY_PATH and it makes no
> difference whatsoever. I've tried on two SPARCs too, running different
> releases of Solaris 10.
>
> Using 'crle' might work, but that is not really a good answer, as it needs
> root access. It should be possible to install an application like R without
> being root. There is something wrong if LD_LIBRARY_PATH can't be used to
> locate libraries.
>
> I can build the whole of the Sage source code (around 300 MB) and don't see
> this failure elsewhere. Instead, there are a number of programs which link
> to libgcc_s.so.1.
>
> I stuck some further information at
>
> http://trac.sagemath.org/sage_trac/ticket/9201
>
> but it basically just confirms what I've written above.
>
>
>
>



--
EI-JI Nakama  <nakama (a) ki.rim.or.jp>
"\u4e2d\u9593\u6804\u6cbb"  <nakama (a) ki.rim.or.jp>

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel