Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-51904

cmake plugin install from archive paths are wrong

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • cmakebuilder-plugin
    • None
    • docker jenkins/jenkins:lts

      When using a cmake that is installed from an archive, the paths for cmake/ctest/cpack are wrong.

      I am using a local build of cmake with the same file structure as the cmake.org archives - contains cmake-blah-version-os-arch/bin/cmake. To illustrate this problem, the example uses the cmake.org archive urls.

      1. run jenkins/jenkins:lts, install common plugins plus Cmake
      2. on configureTools define cmake instance 'cmake-org':
        1. use install 'Extract .zip/.tar.gz'
        2. url of archive on cmake.org (https://cmake.org/files/v3.11/cmake-3.11.3-win64-x64.zip)
        3. Subdirectory of extracted archive 'cmake-3.11.3-win64-x64/bin'
      3. create pipeline job:
      node('cmake&&win64'){
          bat 'type NUL 1>CMakeLists.txt' // "IOException workspace doesn't exist"
          def cmakeTool = tool 'cmake-org'
          echo "tool says ${cmakeTool}"
          cmake arguments: '-V', installation: 'cmake-org'
      }
      

       

      The paths are wrong:

      • The 'tool' step gives the dirname(cmake)
      • 'cmake' step tries to exec "<jenkinshome>/jenkins\tools\hudson.plugins.cmake.CmakeTool\cmake-org\cmake-3.11.3-win64-x64\cmake -V" - 'bin/' is missing
      • dirname(cmake) is not added to PATH - not sure if this is expected

            15knots Martin Weber
            tlynchpin Tim Lynch
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: