• Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Major Major
    • valgrind-plugin
    • None
    • rhel 6.3 and ClearCase

      The ClearCase version control system works by spawning a subshell in "view context". (This is something like chroot). The correct version of files are not available until a view is set. I.e., the file /path/to/source/main.cpp is different depending on which view i set.

      The "Publish Valgrind results" post-build action does not handle this. Wrong version of the source file seems to be copied as seen by the "[Valgrind] copying source file...] log statements. So when clicking on a memory issue in the results wrong version of the file is presented.

      However, files can also be accessed by their abosolute path in /view/myviewname/path/to/source/main.cpp. So, if the plugin could offer an optional "prefix path" which if set was prepended to the from file in the abovementioned copy i think this would help.

          [JENKINS-24562] Publish Valgrind results and ClearCase

          Johannes Ohlemacher added a comment - - edited

          Hello Knut, i am not familiar with ClearCase, so i am not sure, if i fully understand the problem.
          The plugin just reads files from the filesystem via an api provided by jenkins (jenkins handles filesystems on remote build slaves, so the plugin doesn't need to care about that).

          Could you send me a little sample project? (the project/job definition, including a problematic build and the workspace with all files/views checked out)
          i think that could help
          email: johannes [dot] ohlemacher [at] googlemail [dot] com

          Johannes Ohlemacher added a comment - - edited Hello Knut, i am not familiar with ClearCase, so i am not sure, if i fully understand the problem. The plugin just reads files from the filesystem via an api provided by jenkins (jenkins handles filesystems on remote build slaves, so the plugin doesn't need to care about that). Could you send me a little sample project? (the project/job definition, including a problematic build and the workspace with all files/views checked out) i think that could help email: johannes [dot] ohlemacher [at] googlemail [dot] com

          Knut Petter S added a comment -

          The executable contains the source path used at compile time. I suppose this is how the "Publish Valgrind results" step finds the source files to copy into .jenkins/jobs/....../valgrind-plugin/source-files/source_x.tmp. However, the source file path in the executable is not available during the post build step (since it is not running in view context). So what I need is a way to specify a prefix to where the source code is located (when not running in view context as it was duing build time).

          An example:
          Program myApp is compiled from source /vobs/comp1/src/main.cpp and /vobs/comp2/src/file1.cpp. But when publish valgrind results is running the source is avaiable from /view/my_view/vobs/comp1/src/main.cpp and /view/my_view/vobs/comp2/src/file1.cpp.

          By adding a way to specify a "prefix path" or "source substitute path" this would solve the problem. In the example would be "/view/my_view".

          Does this make sense?

          Knut Petter S added a comment - The executable contains the source path used at compile time. I suppose this is how the "Publish Valgrind results" step finds the source files to copy into .jenkins/jobs/....../valgrind-plugin/source-files/source_x.tmp. However, the source file path in the executable is not available during the post build step (since it is not running in view context). So what I need is a way to specify a prefix to where the source code is located (when not running in view context as it was duing build time). An example: Program myApp is compiled from source /vobs/comp1/src/main.cpp and /vobs/comp2/src/file1.cpp. But when publish valgrind results is running the source is avaiable from /view/my_view/vobs/comp1/src/main.cpp and /view/my_view/vobs/comp2/src/file1.cpp. By adding a way to specify a "prefix path" or "source substitute path" this would solve the problem. In the example would be "/view/my_view". Does this make sense?

            existence Johannes Ohlemacher
            knutpett Knut Petter S
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: