From alienalias at gmail.com  Thu Jul 10 15:16:14 2008
From: alienalias at gmail.com (Yulia Arzhaeva)
Date: Thu, 10 Jul 2008 23:16:14 +1000
Subject: [Rd] package has a loading problem
In-Reply-To: <4875CCBE.7060602@epfl.ch>
References: <976fc29a0807100124k2656e95axc76984467af87722@mail.gmail.com>
	<4875CCBE.7060602@epfl.ch>
Message-ID: <976fc29a0807100616o5dbf2c3cy7d4e557ad8c8b134@mail.gmail.com>

Hi,

Yes I have this file already.

Yulia

On Thu, Jul 10, 2008 at 6:47 PM, Mathieu Ribatet
<mathieu.ribatet at epfl.ch> wrote:
> Have you create a zzz.R file in the R folder? I think your issue is related
> to this...
>
> Example of the zzz.R file:
>
> ".First.lib" <-
> function(lib, pkg)
> {
>  library.dynam("your_pkd_name", package = pkg, lib.loc = lib)
>  return(invisible(0))
> }
>
> This is required when you have C/Fortran code. See the writing R extension
> manual.
> Best,
> Mathieu
>
> Yulia Arzhaeva a ?crit :
>>
>> Hello,
>>
>> I have difficulties in finding why I cannot load a custom R package in
>> Linux (Suse 10). When I run R CMD check for a package source folder I
>> get the following message:
>> ".....
>> Error in dyn.load(file, ...) :
>>  unable to load shared library
>> '/home/yarz/projects/Riman/Riman.Rcheck/Riman/libs/Rimanlib.so':
>>  /home/yarz/projects/Riman/Riman.Rcheck/Riman/libs/Rimanlib.so:
>> undefined symbol: immagnify
>> Error in library(Riman) : .First.lib failed for 'Riman'
>> Execution halted
>>
>> It looks like this package has a loading problem: see the messages for
>> details.  "
>>
>> The same message I get when I call library(Riman) inside R after
>> installation of the package.
>> The installation via R CMD INSTALL caused no error messages. However,
>> Riman.so had been built before R CMD INSTALL was called, and put into
>> the source subfolder Riman/inst/libs. It was built via a usual gcc
>> call and linked with all the necessary libraries (so it is weird that
>> references seemed to be undefined).
>>
>> The strange thing is that when I borrow Riman.so built by some other
>> person in my group and replace my copy with it, loading problem
>> disappears!  We both use the same server with Linux Suse 10, the same
>> R installation, the same version of gcc and the same Makefiles for
>> building Riman.so . We went through variables I might have omitted to
>> set correctly, but they seemed OK.
>>
>> If you could give me any hint on what might be a problem, where else
>> to look, I would be very happy. Many thanks in advance.
>>
>> Regards,
>> Yulia
>>
>> ______________________________________________
>> R-devel at r-project.org mailing list
>> https://stat.ethz.ch/mailman/listinfo/r-devel
>>
>
> --
> Institute of Mathematics
> Ecole Polytechnique F?d?rale de Lausanne
> STAT-IMA-FSB-EPFL, Station 8
> CH-1015 Lausanne   Switzerland
> http://stat.epfl.ch/
> Tel: + 41 (0)21 693 7907
>
>
>



[Rd] package has a loading problem
Yulia Arzhaeva