[Quantian-general] Quantian and Java

Dirk Eddelbuettel edd at debian.org
Sun Mar 19 18:09:02 UTC 2006


Hi Simon,

Thanks for the quick feedback!

On 19 March 2006 at 11:46, Simon Urbanek wrote:
| Hi Dirk,
| 
| On Mar 18, 2006, at 10:46 PM, Dirk Eddelbuettel wrote:
| 
| > | But I am having a problem with the rJava library for R (needed  
| > for JGR)
| > | in Quantian_0.7.9.2. It seems to be a Java problem. I do library 
| > (JGR) or
| > | library(rJava) and get:
| > |
| > | Error in dyn.load ...
| > | unable to load ... rJava.so
| > | libjvm.so: cannot open shared object file: No such file or directory
| >
| > I noticed that too post-release.  However, the good news is that  
| > this seems
| > to happen only when you start R directly, or via ESS, and can be  
| > circumvented
| > (see below).  I suspect that because nobody tells R (at run-time)  
| > where the
| > Java libraries are, libjvw.so is not found.
| >
| 
| It seems as if your R build is not Java-aware. All necessary paths  
| are set in the R script, so it works both in the shell and ESS if  
| compiled properly. R uses the same mechanism as rJava so you should  
| see the same output at configure time of R (i.e. whether Java support  
| is enabled and where Java lives). My guess is that you compiled R  
| before having Java installed and thus R didn't know about Java at  
| that time. In that case, you have to set LD_LIBRARY_PATH manually (it  
| still helps to run the configure script of R or JRI to see what the  
| correct path is).

Spot on. The R in Quantian is the normal Debian package I maintain which
can't be Java aware as Debian would not / could not depend on Sun's
not-really-freally-free-to-the-Debian-standards software.

So I need to remember to edit that manually for Quantian builds. Then it
won't matter how R is started and rJava will 'just work'.  Given both the
client and server installation of Java 1.5.0 in Quantian, any recommendation
for which one I should pick?

| The whole issue is quite messy, because Sun's Java moves around with  
| updates. We are working on a better solution that will allow you to  
| run something like `R CMD java-configure' to update the paths in an  
| already installed R - it will hopefully make it to the R 2.3 release.

Sounds good.

Thanks again,  Dirk

-- 
Hell, there are no rules here - we're trying to accomplish something. 
                                                  -- Thomas A. Edison



More information about the Quantian-general mailing list