raddebugger icon indicating copy to clipboard operation
raddebugger copied to clipboard

Varying root of relative paths

Open forksnd opened this issue 1 year ago • 2 comments

In the .raddbg_project file, some relative paths (like target.executable) are calculated from the path in which the .raddbg_project file is located while other paths (like file_path_map.dest) seem to be calculated from the present working directory. Uniformity in this would be good -- ideally, all relative paths should be calculated from the path of the .raddbg_project file.

forksnd avatar Oct 16 '24 11:10 forksnd

Currently, file_path_maps should not have any path transformations applied to them. You can use relative or absolute paths and they should simply be preserved how you input them (unlike some other things which are written as relative to the user/project file). Are you seeing different behavior?

ryanfleury avatar Oct 16 '24 20:10 ryanfleury

Imagine a folder structure like:

A
|-B
   |-a.exe
|-C
  |-D
  |-E
    |-a.raddbg_project

When I launch raddbg, the working directory is A. To launch a.exe, I have to add the target.executable as ../../B/a.exe in the project file (since this path is relative to the project file). But to map A/C/D as C:/src, the file_path_map.dest has to be set as C/D (since it seems to be relative to the working directory).

forksnd avatar Oct 18 '24 06:10 forksnd

This should now all be resolved as of 0.9.18; file path maps should not have any path transformations applied to them, and all relativized paths are done so w.r.t. the containing config file.

ryanfleury avatar May 20 '25 22:05 ryanfleury