KDAB / hotspot

The Linux perf GUI for performance analysis.
4.16k stars 257 forks source link

add option to set custom source paths #497

Closed lievenhey closed 1 year ago

lievenhey commented 1 year ago

this patch add allows the user to add a custom source path which will overwrite the source path provided in the binary this makes the disassembler, ... work if the source code directory was moved after creating the binary

closes: #418

GitMensch commented 1 year ago

Tested with the CI result:

So sadly: not successful. When it works it seems to like this would close #482 (currently not GH-related).

lievenhey commented 1 year ago

thanks for testing. I fixed the --sourcePaths option and added reloading if sourcePaths changes

GitMensch commented 1 year ago

fixed the --sourcePaths option and added reloading if sourcePaths changes

Thanks, this works nearly as expected now. It seems that while the entries that were included in the GUI are not shown in the configuration after a reload of the application, they are still active (which is not necessarily bad, I actually prefer those to be saved) - maybe they are needed to be included when the setting page is opened?

Not sure how you'd show "persistent" and "per session" entries there (I'd personally mostly need "per session" or "per configuration file", because different projects have the same binary name but the source is in different directories) .

Note that in any case this PR missed to add the option (now also in --help) to https://github.com/KDAB/hotspot/blob/master/README.md#command-line-options

milianw commented 1 year ago

@GitMensch I think the per-session vs. user settings is a general issue we need to tackle somehow - can you please open a ticket to track that?

the rest of this pull request is now mergeable I believe