Bug 3295 - Source window cannot find the source code if it gets a relative path from the debuginfo
Summary: Source window cannot find the source code if it gets a relative path from the...
Status: RESOLVED FIXED
Alias: None
Product: frysk
Classification: Unclassified
Component: general (show other bugs)
Version: unspecified
: P2 normal
Target Milestone: ---
Assignee: Adam Jocksch
URL:
Keywords:
Depends on:
Blocks: 1633
  Show dependency treegraph
 
Reported: 2006-10-02 19:33 UTC by Rick Moseley
Modified: 2006-10-09 18:32 UTC (History)
2 users (show)

See Also:
Host:
Target:
Build:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Rick Moseley 2006-10-02 19:33:34 UTC
If a relative path shows up in the debuginfo of a task to debug with the source
window it cannot find the source unless frysk was started in the same directory
as the source was originally compiled.

According to Andrew, the debuginfo contains the directory in which the compiler
was activated and therefore the path to the source code should be able to be
reconstructed.
Comment 1 Andrew Cagney 2006-10-03 16:17:57 UTC
And an include file search path, i.e., there is complete information.

I'm hanging it off 1633 - source window blocker - although I've a hunch that
this is more of a DOM blocker?
Comment 2 Adam Jocksch 2006-10-09 18:32:29 UTC
I've committed a fix for this. It wraps dwfl_line_comp_dir() from libdwfl.

2006-10-09  Adam Jocksch  <ajocksch@redhat.com>

	* DwflLine.java: Reformatted.
	(getCompilationDir): Added.
	* cni/DwflLine.cxx (dwfl_linecomp_dir): Added.

2006-10-09  Adam Jocksch  <ajocksch@redhat.com>

	* DOMFactory.java (createDOM): Now checks for a relative path to the
	source file and uses the compilation directory instead if a relative
	path is found.