United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-6400872 REGRESSION: Java Compiler cannot find jar files referenced by other
JDK-6400872 : REGRESSION: Java Compiler cannot find jar files referenced by other

Details
Type:
Bug
Submit Date:
2006-03-20
Status:
Closed
Updated Date:
2010-05-08
Project Name:
JDK
Resolved Date:
2006-05-13
Component:
tools
OS:
solaris_2.5.1,linux,solaris_10,windows_xp
Sub-Component:
javac
CPU:
x86,sparc
Priority:
P4
Resolution:
Fixed
Affected Versions:
5.0,5.0u7,6
Fixed Versions:

Related Reports
Backport:
Duplicate:
Duplicate:
Duplicate:
Relates:
Relates:

Sub Tasks

Description
A DESCRIPTION OF THE REGRESSION :
I have tried the exact same compile command on Java 1.4, Java 1.5, and Java 1.6 beta. Compiling with 1.4 and 1.5 is fine. When I execute the command against 1.6 compiler I get:

---------------------------------------------------------------------------------------------------------------------------------

error: error reading lib\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.
\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\commons-logging-api-1.0.2.jar; The system cannot find the path specified
error: error reading lib\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.
\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\commons-collections-api-1.0.2.jar; The system cannot find the path specified
error: error reading lib\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.
\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\commons-fileupload-api-1.0.2.jar; The system cannot find the path specified

---------------------------------------------------------------------------------------------------------------------------------

I recieve many of these messages, and some are duplicated. The jar files in question are in the lib directory and as stated earlier are found by 1.4 and 1.5. Looking at the MANIFEST of one of my jars, it references others using './jarname.jar', and even referenced it's self. I removed the self reference and the './' from all the other jar files but still did not work. Several of the jars point to each other in the MANAFESTS Class-Path element.

REPRODUCIBLE TESTCASE OR STEPS TO REPRODUCE:
Multiple jar files, each with a Class-Path in the MANIFEST.MF. The jar files point to each other, referencing each other as ./jarname.jar. Use these jar files in the -classpath of the compiler.

RELEASE LAST WORKED:
5.0 Update 4

RELEASE TEST FAILS:
mustang-beta

EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
I expected the compile to be successful as it was using both 1.4 and 1.5
ACTUAL -
C:\WORKSPACE>"%JAVA_HOME%\bin\javac" -classpath lib/core.jar;lib/beans.jar;C:\jboss\server\default\lib\jboss-j2ee.jar -d
 /bin/classes -sourcepath /src src/XMLImport.java
error: error reading lib\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.
\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.
\beans.jar; The system cannot find the path specified
error: error reading lib\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.
\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.
\apps.jar; The system cannot find the path specified
error: error reading lib\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.
\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.
\inbound.jar; The system cannot find the path specified
error: error reading lib\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.
\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.
\commons-collections-2.1.jar; Filename too long
error: error reading lib\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.
\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.
\commons-logging-api-1.0.2.jar; Filename too long
error: error reading lib\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.
\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.\.
\commons-fileupload-1.0.jar; Filename too long
 ...

                                    

Comments
EVALUATION

Reproduced test case on Linux
                                     
2006-05-02
EVALUATION

The check whether a file was already in the path did not use the canonical path of the file.

The fix is to keep a cache of the canonical values of the entries on the path, and to check the canonical value of any new entries against that list.
                                     
2006-05-02



Hardware and Software, Engineered to Work Together