Bug 160327

Summary: Missing /usr/{share,lib}/java-1.3.1 breaks ant with JDK1.3
Product: [Fedora] Fedora Reporter: Carsten Clasohm <clasohm>
Component: jpackage-utilsAssignee: Thomas Fitzsimmons <fitzsim>
Status: CLOSED RAWHIDE QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: 4   
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2006-02-06 20:33:14 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Carsten Clasohm 2005-06-14 14:18:50 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.8) Gecko/20050513 Fedora/1.0.4-1.3.1 Firefox/1.0.4

Description of problem:
With jpackage-utils-1.6.3-1jpp_1rh, ant-1.6.2-3jpp_8fc and the Sun JDK 1.3.1, running ant results in this error message:

Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/tools/ant/launch/Launcher


Version-Release number of selected component (if applicable):
jpackage-utils-1.6.3-1jpp_1rh

How reproducible:
Always

Steps to Reproduce:
Install the above packages and the Sun JDK 1.3.1, set JAVA_HOME to point to the 1.3.1 JDK, and run "ant".


Actual Results:  Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/tools/ant/launch/Launcher

With JAVA_HOME pointing to the 1.4 JDK, ant runs fine.

Additional info:

The reason for the above error message is a broken CLASSPATH. Replacing the eval with echo in the last line of /usr/bin/ant shows this:

exec "/usr/java/jdk1.3/bin/java" -classpath "/usr/bin/build-classpath: error: JAVAVER_LIBDIR /usr/share/java-1.3.1 does not exist or is not a directory:/usr/bin/build-classpath: error: JAVAVER_LIBDIR /usr/share/java-1.3.1 does not exist or is not a directory:/usr/java/jdk1.3/lib/tools.jar:/opt/oracle10/JRE:/opt/oracle10/jlib:/opt/oracle10/rdbms/jlib:/opt/oracle10/network/jlib" -Dant.home="/usr/share/ant" -Dant.library.dir="/usr/share/ant/lib" org.apache.tools.ant.launch.Launcher -lib ""

Apparently one of the shell scripts that initializes the environment before running ant expects /usr/share/java-1.3.1 to exist, and puts its error message into the CLASSPATH.

Manually creating the two directories /usr/share/java-1.3.1 and /usr/lib/java-1.3.1 fixes this problem.

Either these two directories should be added to the jpackage-utils RPM, or the responsible shell script should be modified to ignore non-existant directories.

Comment 1 Thomas Fitzsimmons 2005-10-01 21:37:30 UTC
OK, I'll add those directories to jpackage-utils.


Comment 2 Thomas Fitzsimmons 2006-02-06 20:33:14 UTC
Directories added to jpackage-utils-1.6.6-1jpp_2rh.  Closing.