I have a problem with my dynamically loaded code in R not finding pow_ii, which for some time I thought was because library f2c is not on my Sparcstation. However, I have now been experiencing the same problem in Linux, with all the proper libraries in place. My incomplete understanding of elf and shared libraries does not help, but when compiling a complete program I usually muddle through. However, in the case of dynamically loading code into R, I am not sure whether it is my dse.so or R which should have the knowledge of where to find /usr/lib/libf2c.so*. I haven't had much success trying to configure so that that information is in dse.so. None of the usual things seem to help, so I suspect R itself needs to be able to find the library. If someone can explain this I would very much appreciate it. Paul Gilbert -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- 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: r-devel-request@stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
Paul Gilbert <pgilbert@bank-banque-canada.ca> writes:> I have a problem with my dynamically loaded code in R not finding pow_ii, which > for some time I thought was because library f2c is not on my Sparcstation. > However, I have now been experiencing the same problem in Linux, with all the > proper libraries in place. > > My incomplete understanding of elf and shared libraries does not help, but when > compiling a complete program I usually muddle through. However, in the case of > dynamically loading code into R, I am not sure whether it is my dse.so or R > which should have the knowledge of where to find /usr/lib/libf2c.so*. I haven't > had much success trying to configure so that that information is in dse.so. None > of the usual things seem to help, so I suspect R itself needs to be able to find > the library. If someone can explain this I would very much appreciate it.One thing you can do is to check the R.binary file with "nm -g" to find out what symbols are defined in it. On my machine R.binary includes pow_dd and pow_di but not pow_ii. $ nm -g R.binary ... 08108c30 T pnt U popen 080ef370 T pow_dd 080ef460 T pow_di 08106c80 T ppois ... This means that you will have to include a reference to the f2c library when you are making the dse.so object. I'm not sure of the sequence invoked by "R INSTALL dse" but it may be that you can override the library specification in the makefile by exporting an appropriate value for the environment variable SHLIBLDFLAGS. -- Douglas Bates bates@stat.wisc.edu Statistics Department 608/262-2598 University of Wisconsin - Madison http://www.stat.wisc.edu/~bates/ -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- 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: r-devel-request@stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
> To: Paul Gilbert <pgilbert@bank-banque-canada.ca> > Cc: R-devel <R-devel@stat.math.ethz.ch> > Subject: Re: f2c > From: Douglas Bates <bates@stat.wisc.edu> > Date: 02 Apr 1998 12:36:56 -0600> Paul Gilbert <pgilbert@bank-banque-canada.ca> writes: > > > I have a problem with my dynamically loaded code in R not finding > > pow_ii, which for some time I thought was because library f2c is > > not on my Sparcstation. > > However, I have now been experiencing > > the same problem in Linux, with all the proper libraries in place. > > > > My incomplete understanding of elf and shared libraries does not > > help, but when compiling a complete program I usually muddle through. > > However, in the case of dynamically loading code into R, I am not > > sure whether it is my dse.so or R which should have the knowledge > > of where to find /usr/lib/libf2c.so*. I haven't had much success > > trying to configure so that that information is in dse.so. None > > of the usual things seem to help, so I suspect R itself needs to > > be able to find the library. If someone can explain this I would > > very much appreciate it.DB> One thing you can do is to check the R.binary file with "nm -g" to find DB> out what symbols are defined in it. On my machine R.binary includes DB> pow_dd and pow_di but not pow_ii. This is a general problem we need a solution to. Recently, Kurt Hornik has changed the configuration procedures so that fortran is located and used to load R. I thought this would fix this kind of problem. (Any references to fortran things like pow_ii should be removed from the C sources). I'd suggest that you get in touch with Kurt directly: Kurt.Hornik@ci.tuwien.ac.at to sort this out. Ross -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- 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: r-devel-request@stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._