Gentoo Archives: gentoo-java

From: Alistair Bush <ali_bush@g.o>
To: gentoo-java@l.g.o
Cc: gentoo-dev@l.g.o
Subject: [gentoo-java] java-utils-2.eclass patch. Support for BUILD_DEPEND being recorded within package.env.
Date: Thu, 04 Jun 2009 11:37:31
Message-Id: 4A27B20E.2080202@gentoo.org
Firstly, fellow developer please review this eclass patch and read on if
you are interested in what it actually does.

Java developers:

The following patch adds 3 new values to our package.env

PVR and CATEGORY being the easy ones.  These are being added because I
think they should be there and they will help with implementing a
paludis re-emerge-everything-java script.

the 3rd BUILD_DEPEND records the packages/jars that have been passed as
parameters to our java functions ( jar-from, getjars, getjar ) and also
have --build-only specified.  The format is exactly like package.env's
DEPEND variable. The main reason for this patch is to allow Serkan to
add --build-only dependencies to the classpath for java-dep-check.
java-config support is not currently planned but this may change if need be.

Here are some example package.env files.

# more
/var/tmp/portage/app-office/hourglass-0.7.2/image/usr/share/hourglass/package.env
DESCRIPTION="A PSP (personal software process) time tracking utility
written in Java"
GENERATION="2"
SLOT="0"
CATEGORY="app-office"
PVR="0.7.2"
CLASSPATH="/usr/share/hourglass/lib/hourglass.jar"
DEPEND="log4j.jar@log4j:jcommon.jar@jcommon-1.0:jdom.jar@jdom-1.0"
VM=">=virtual/jre-1.5"
BUILD_DEPEND="ant.jar@ant-core"
TARGET="1.5"
SOURCE="1.5"
JAVADOC_PATH="/usr/share/doc/hourglass-0.7.2/html/api"
JAVA_SOURCES="/usr/share/hourglass/sources//hourglass-src.zip"
MERGE_VM="sun-jdk-1.7"
MERGE_COMPILER="javac"

 # more /var/tmp/portage/dev-java/sbaz-1.25/image/usr/share/sbaz/package.env
DESCRIPTION="A system used by Scala enthusiasts to share computer files
with each other."
GENERATION="2"
SLOT="0"
CATEGORY="dev-java"
PVR="1.25"
CLASSPATH="/usr/share/sbaz/lib/sbaz.jar"
DEPEND="scala-library.jar@scala"
VM=">=virtual/jre-1.5"
BUILD_DEPEND="servlet-api.jar@servlet-api-2.4:ant-contrib"
TARGET="1.5"
SOURCE="1.5"
MERGE_VM="sun-jdk-1.7"
MERGE_COMPILER="javac

Attachments

File name MIME type
java-utils-2.eclass.patch text/plain