Re: [Rd] Canonical package directory name for JAR files?

From: Roebuck,Paul L <proebuck_at_mdanderson.org>
Date: Wed, 08 Feb 2012 16:31:00 -0600


What would be involved in modifying rJava's .jpackage() method to search in both locations ('java' and/or 'jars') for JAR files to be added to the CLASSPATH on JVM initialization?

On 2/8/12 4:12 PM, "William Dunlap" <wdunlap_at_tibco.com> wrote:

> We don't "mandate" a given JDK (including the compiler,
> javac), but we do supply the JRE.  We do require that the
> java compiler be able to produce code that the JRE accepts
> (we test-run javac with a variety of common version-type
> flags to try to find one that works with our JRE).
> 
> It is source:pkg/java/{src,prebuiltjars,Makevars} -> binary:pkg/jars,
> roughly parallel with source:pkg/src -> binary:pkg/libs.
> 
> Bill Dunlap
> Spotfire, TIBCO Software
> wdunlap tibco.com
> 
>> -----Original Message-----
>> From: Simon Urbanek [mailto:simon.urbanek_at_r-project.org]
>> Sent: Wednesday, February 08, 2012 1:46 PM
>> To: William Dunlap
>> Cc: Roebuck,Paul L; R-Devel
>> Subject: Re: [Rd] Canonical package directory name for JAR files?
>> 
>> Unfortunately we cannot mandate JDK so packages have to use the build
>> stage for compilation so the S+ model doesn't work. I think java is
>> more consistent than src/java -> jars
>> 
>> Sent from my iPhone
>> 
>> On Feb 8, 2012, at 3:27 PM, William Dunlap <wdunlap_at_tibco.com> wrote:
>> 

>>> For what it is worth, the S+ package system uses
>>> the java directory in source packages to store
>>> java source code (under pkg/java/src/, using the usual
>>> directory structure that follows the class structure
>>> under there), prebuilt jar files (in pkg/java/prebuiltjars,
>>> no subdirectories), and a Makevars file (pkg/java/Makevars)
>>> that can define the java compiler flags PKG_JAVAC_CLASSPATH
>>> and PKG_JAVACFLAGS, e.g.,
>>>
>>> PKG_JAVAC_CLASSPATH=$(SHOME)/java/jre/libext/jaxp.jar;$(SHOME)/java/jre/libe
>>> xt/batik.jar
>>> PKG_JAVACFLAGS=-verbose -g
>>>
>>> INSTALL compiles the java code in pkg/java/src and puts
>>> it into into a jar file called pkg/jars/pkg.jar. All of
>>> the jar files in pkg/java/prebuiltjars are copied into
>>> pkg/jars as well. The installed package has a jars directory
>>> but no java directory (i.e., {java,jars} <=> {src,libs}).
>>>
>>> library(pkg) adds pkg/jars to the CLASSPATH so .Java calls
>>> will find it.
>>>
>>>
>>> Bill Dunlap
>>> Spotfire, TIBCO Software
>>> wdunlap tibco.com
>>>
>>>> -----Original Message-----
>>>> From: r-devel-bounces_at_r-project.org [mailto:r-devel-bounces_at_r-project.org]
>>>> On Behalf Of
>> Roebuck,Paul L
>>>> Sent: Wednesday, February 08, 2012 8:14 AM
>>>> To: Simon Urbanek
>>>> Cc: R-Devel
>>>> Subject: Re: [Rd] Canonical package directory name for JAR files?
>>>> 
>>>> On 2/7/12 5:37 PM, "Simon Urbanek" <simon.urbanek_at_r-project.org> wrote:
>>>> 
>>>>> On Feb 7, 2012, at 4:34 PM, Roebuck,Paul L wrote:
>>>>> 
>>>>>> We have an R package which needs to include a JAR file.
>>>>>> Is there a canonical directory for it?
>>>>> 
>>>>> rJava defines "java" for that purpose (see ?.jpackage).
>>>>> How canonical that is may be open for debate ;)
>>>> 
>>>> Yeah, when I wrote Java stuff, that was the Java source code
>>>> root directory. Yet, 'lib' (which was the directory where JAR
>>>> files lived in Java projects) seems inappropriate for non-Java
>>>> projects.
>>>> 
>>>> But 'java' appears to be the de-facto standard for R packages,
>>>> so...
>>>> 
>>>> ______________________________________________
>>>> R-devel_at_r-project.org mailing list
>>>> https://stat.ethz.ch/mailman/listinfo/r-devel

>>>
>>>


R-devel_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel Received on Wed 08 Feb 2012 - 22:33:14 GMT

This quarter's messages: by month, or sorted: [ by date ] [ by thread ] [ by subject ] [ by author ]

All messages

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Thu 09 Feb 2012 - 01:20:15 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-devel. Please read the posting guide before posting to the list.

list of date sections of archive