https://issues.apache.org/bugzilla/show_bug.cgi?id=50091
Summary: <java jar=".."> task referring to installed optional
packages with nested <jvmarg
value="-Djava.ext.dirs=.."/> fails with
NoClassDefFoundError
Product: Ant
Version: 1.8.1
Platform: PC
OS/Version: Linux
Status: NEW
Severity: normal
Priority: P2
Component: Core tasks
AssignedTo: [email protected]
ReportedBy: [email protected]
Created an attachment (id=26174)
--> (https://issues.apache.org/bugzilla/attachment.cgi?id=26174)
sample project to illustrate the problem
testcase:
I have two classes in two jars. Both jars are located in the lib directory.
Using
<java jar="lib/main.jar" fork="true" failonerror="false" dir=".">
<jvmarg value="-Djava.ext.dirs="lib""/>
</java>
fails with NoClassDefFoundError
Using deprecated syntax
<java jar="lib/main.jar" jvmargs="-Djava.ext.dirs="lib"" fork="true"
failonerror="false" dir="."/>
works just fine.
On Windows platform the issue doesn't occur.
Seems to be a sequencing issue when building the commandline: -Djava.ext.dirs
has to preceed the -jar option.
Attached is a sample project to illustrate the problem.
My platform: Ubuntu Linux 10.4, 2.6.32-24-generic kernel, x86_64
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.