Ozone, how to load a large source tree?

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • Ozone, how to load a large source tree?

    I am just trying out Ozone after seeing it at Arm TechCon today. I have a large makefile based project that I would like to bring some debug capability to. I have done some very limited debugging via a roundabout method using TrueStudio, which I believe just automates the interface over gdb-server and wraps a gui around it. But I would like to get set up with full streaming trace.

    The ELF file output loads with no problem in Ozone, but there are hundreds of source and header files which are not found and will need to be located. Locating each one manually is not a tenable solution. Is there a way to automate thing, find or import automatically based on a root path?

    Also, it seems like even if I manually add the source file and save the project, that file path is not stored anywhere in the project.

    Any solutions? Both of these problems are total dealbreakers for using Ozone :S
  • Hi,

    thanks for trying out Ozone!
    Unfortunately, my colleague responsible for questions regarding Ozone is out of Office today, therefore I will take over for today.

    The ELF file output loads with no problem in Ozone, but there are hundreds of source and header files which are not found and will need to be located. Locating each one manually is not a tenable solution. Is there a way to automate thing, find or import automatically based on a root path?

    There are 3 possible reasons for this:
    1) The missing source and header files are not used in the configuration used to build the ELF file. Therefore, they are not linked in the resulting application and also are not referred to in the ELF file.
    2) The debug information were partly stripped out from the ELF-file due to a compiler option or as a part of a post-build procedure.
    3) This is bug in the ELF-parser of Ozone.

    Would it be possible to provide a project which can be used to reproduce the issue on our side?
    You can contact me via PM or the SEGGER support team via Mail if have a project you can send us but do not wish to publish in the forum.


    Best regards,
    Niklas
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.
  • Hi,

    It looks like your elf-file includes insufficient source information or relative source file paths which are not relative to the output file.

    For these cases you can use File Path Resolution functions in Ozone, via the Console Window or in your project file.
    With these functions you can set the root for relative files, add additional search directories and substitute parts of absolute paths.

    For more information have a look at Chapter 6.3 "File Path Resolution" of the Ozone User Manual.

    Best regards
    Johannes
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.
  • Interesting ... if I do Project.SetRootPath("..."), where "...." is the absolute path to the root directory where the makefile build is invoked, then all the source files auto-populate.


    By adding that line into the OnProjectLoad function manually, then all the right settings seem to persist when I quit out and reload the project.

    Are there any relative paths or root path information present in the ELF file? All I can see from objdump and readelf are the file names, but without any paths. Even when examining the elf file that *did* load without issue, I still only see plain filenames, but maybe there is some field that I am not seeing.
  • Hi,

    Glad to read this is solved.
    Adding Project.SetRootPath("...") to OnProjectLoad is the right way.

    Some information about the file paths:
    Your application seems to be built with relative path names, relative to the makefile execution path.
    In the elf file, source file and path information are spread across different sections and entries.
    With the information from objdump or readelf you can reconstruct the full path with the additional fields of the file description,
    this is what Ozone does as well.

    Best regards
    Johannes
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.