Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » Java Development Tools (JDT) » Trouble mapping object file to source file(Eclipse cannot locate the source for the object code in a jar file and then prompts be to chance the source the attached source. I enter the source directory and Eclipse repromts for the attached sour)
Trouble mapping object file to source file [message #985606] Thu, 15 November 2012 14:32 Go to next message
Jim Anderson is currently offline Jim AndersonFriend
Messages: 109
Registered: October 2014
Senior Member
When I run 'about Eclipse SDK' from the menu, I get:

Eclipse SDK

Version: 3.5.2
Build id: M20100211-1343


My platform is CrunchBang Linux:

Distributor ID: Debian
Description: Debian GNU/Linux 6.0 (squeeze)
Release: 6.0
Codename: squeeze


If I run 'uname -a', the release is:

2.6.32-5-686

I have been running Eclipse for a few years with the configuration I have been using. The major change in my work in the past week is that I'm now working, and debugging, more with source code in multiple jars.

The set up I use is to link Eclipse source code back to the source code in my development directory, which is outside the Eclipse working directory. When I work in Eclipse, it is finding and displaying the correct source code - no problem here.

When I try to debug, my program starts up fine, and I can step through the source code that is in the directory that contains the 'main' method with no trouble. However, when I reach code that is in class 'Pot' and I try to step into the code, Eclipse pops up a new window 'Pot.class', in a new tab, that tells me that 'The source attachment does not contain the source for the file Pot.class'. (I have attached a snapshot of that window).

When I select the 'Change Attached Source' button, a navigation window pops up and I navigate to the directory containing the source for Pot.java and select it. After I hit the 'OK' button, Eclipse reverts back to the former context and continues to prompt me to 'Change Attached Source'.

The bottom line is that I can not step through source code that is the auxiliary jar file.

BTW, I tried rebuilding the project after I ran into this problem, but the same behavior continues. After rebuilding, I looked into the work directory and by looking at time stamps, I concluded that the jar files in the eclipse work directory are getting built from the source files in my development directory.

Does anyone have any suggestions for me to try? Thank you in advance.

Jim
Re: Trouble mapping object file to source file [message #985661 is a reply to message #985606] Thu, 15 November 2012 16:09 Go to previous messageGo to next message
Jim Anderson is currently offline Jim AndersonFriend
Messages: 109
Registered: October 2014
Senior Member
No Message Body
Re: Trouble mapping object file to source file [message #985668 is a reply to message #985661] Thu, 15 November 2012 16:14 Go to previous message
Jim Anderson is currently offline Jim AndersonFriend
Messages: 109
Registered: October 2014
Senior Member

I resolved this issue. The problem was that when selected the source directory, I was selected the lowest directory level that contained my java file. What Eclipse was looking for was the root source directory under which my qualfied directorys are found.

Wrong entry: .../src/abc/efg, where efg has the jave file

Correct entry .../src, where all the java files under the src directory can be found be Eclipse.

Jim

Previous Topic:simple way to just open an eclipse project?
Next Topic:Cannot update ADT on Mac
Goto Forum:
  


Current Time: Thu Apr 25 12:05:49 GMT 2024

Powered by FUDForum. Page generated in 0.03179 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top