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

From: William Dunlap <wdunlap_at_tibco.com>
Date: Wed, 08 Feb 2012 20:27:25 +0000

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/libext/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@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 - 20:29:43 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 Wed 08 Feb 2012 - 22: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