Bug 65557 - Relative locations in .classpath are ignored.
Summary: Relative locations in .classpath are ignored.
Status: RESOLVED WORKSFORME
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.0   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 3.0 M8   Edit
Assignee: JDT-Core-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-06-03 11:21 EDT by Greg Lapouchnian CLA
Modified: 2004-10-27 06:47 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Greg Lapouchnian CLA 2004-06-03 11:21:29 EDT
Trying to set a classpath entry in .classpath to point to a JAR file relative to
the project ignores ".." in the location.

I added an entry manually:
<classpathentry kind="lib" path="../EJB/weblogic/Converter.jar"/>
and once I start eclipse i get the following error in the Problems view:
"Project TEST is missing required library: 'EJB/weblogic/Converter.jar'."

In the Java Build Path settings under Project Properties it also displays an
error message: "Build path entry is missing: /EJB/weblogic/Converter.jar"

So Eclipse completely ignores ".." to go one folder up and searches in the
project folder.

-- Eclipse 3.0 M8
Comment 1 Olivier Thomann CLA 2004-06-03 11:25:12 EDT
Did you try to do that same steps using the Java build path wizard? The
.classpath is not supposed to be changed manually.
Comment 2 Greg Lapouchnian CLA 2004-06-03 11:31:56 EDT
In the Project Properties -> Java Build Path -> Libraries there are two options
to add a JAR file to the classpath
- "Add JARs" which will only browse the folders below the project's root folder
- "Add External JARs" which will add an absolut path to the .classpath file

So these options do not allow me to add a path entry relative to the project so
multiple developers with the same directory structure could utilise one common
.classpath.
Comment 3 Olivier Thomann CLA 2004-06-03 11:42:08 EDT
Why don't you use a classpath variable? Instead of referencing directly the
jars, you can define a classpath variable that can be updated on the different
configurations. Like this, your .classpath file would not change.
Comment 4 Greg Lapouchnian CLA 2004-06-03 11:45:21 EDT
Thanks for pointing me to this feature, I had not seen it before.