Bug 983394

Summary: java ant not working properly
Product: [Fedora] Fedora Reporter: ell1e <el>
Component: jpackage-utilsAssignee: Michal Srb <msrb>
Status: CLOSED DUPLICATE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: high Docs Contact:
Priority: unspecified    
Version: 19CC: akurtako, java-sig-commits, jcapik, jerboaa, kdaniel, mizdebsk, mmatejov, msrb, sochotni, tradej
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-07-11 08:13:42 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description ell1e 2013-07-11 06:46:19 UTC
Description of problem:
I installed ant.noarch and tried to use it with "ant .". This is what I get:
bash-4.2$ ant .
Error: Could not find or load main class org.apache.tools.ant.launch.Launcher

Version-Release number of selected component (if applicable):
ant: 1.8.4-6.fc19
bash-4.2$ java -version
openjdk version "1.8.0-internal"
OpenJDK Runtime Environment (build 1.8.0-internal-0)
OpenJDK 64-Bit Server VM (build 25.0-b31-internal, mixed mode)
bash-4.2$
java-1.8.0-openjdk-devel: 1.8.0.0-0.7.b89.fc19 (fixed version for bug #968814)

How reproducible:
100%

Steps to Reproduce:
1. Install openjdk 1.8.0 (Fixed version for bug #968814)
2. Install ant using yum install ant.noarch
3. Try "ant ."

Actual results:
Error: Could not find or load main class org.apache.tools.ant.launch.Launcher

Expected results:
It works

Additional info:

Comment 1 Michal Srb 2013-07-11 08:04:21 UTC
Hi Jonas,

Thanks for reporting this. The problem here is that java 8 identifies itself as:
$ java -fullversion
openjdk full version "1.8.0-internal-0"

sed regexp in /usr/share/java-utils/java-functions (set_jvm_dirs()) can't detect java version in this output and build-classpath will always fail because of that.

$ build-classpath ant
/usr/bin/build-classpath: error: JAVAVER_LIBDIR /usr/share/java- does not exist or is not a directory

Reassigning to jpackage-utils.

Comment 2 Mikolaj Izdebski 2013-07-11 08:13:42 UTC

*** This bug has been marked as a duplicate of bug 982683 ***