-
Bug
-
Resolution: Unresolved
-
Minor
-
None
-
Windows + visual studio 2015 / Linux + unix makefiles
Jenkins ver. 2.176.1
cmake builder plugin Version 2.6.2
I have created a Jenkins pipeline that covers both windows and linux.
However it appears that cmakeBuild does not use buildType correctly for visual studio
For Linux is correctly adds -DCMAKE_BUILD_TYPE=Debug or Release in the configure step
However for windows the CMAKE_BUILD_TYPE variable is ignored:
17:47:24 Manually-specified variables were not used by the project: 17:47:24 17:47:24 CMAKE_BUILD_TYPE
And subsequently in the --build step, the --config is unused. Resulting in a Debug-by-default build with the visual studio generator.
-config Debug or -config Release (depending on buildType should be added to the --build phase for windows (and CMAKE_BUILD_TYPE should not be used for visual studio generator)
The current workaround to this is adding --config Debug/Release explicitly in the steps:
steps: [[args: '--config Debug', withCmake: true]]
Which of course is less than ideal if the buildType property is available.
[JENKINS-58351] buildType is used incorrectly for visual studio builds
Summary | Original: buildType is used incorrectly for windows builds | New: buildType is used incorrectly for visual studio builds |
Description |
Original:
I have created a Jenkins pipeline that covers both windows and linux. However it appears that cmakeBuild does not use buildType correctly for windows. For Linux is correctly adds -DCMAKE_BUILD_TYPE=Debug or Release in the configure step However for windows the CMAKE_BUILD_TYPE variable is ignored: {code:java} 17:47:24 Manually-specified variables were not used by the project: 17:47:24 17:47:24 CMAKE_BUILD_TYPE {code} And subsequently in the --build step, the --config is unused. Resulting in a Debug-by-default build on windows. --config Debug or --config Release (depending on buildType should be added to the --build phase for windows (and CMAKE_BUILD_TYPE should not be used for windows) The current workaround to this is adding --config Debug/Release explicitly in the steps: {code:java} steps: [[args: '--config Debug', withCmake: true]] {code} Which of course is less than ideal if the buildType property is available. |
New:
I have created a Jenkins pipeline that covers both windows and linux. However it appears that cmakeBuild does not use buildType correctly for visual studio For Linux is correctly adds -DCMAKE_BUILD_TYPE=Debug or Release in the configure step However for windows the CMAKE_BUILD_TYPE variable is ignored: {code:java} 17:47:24 Manually-specified variables were not used by the project: 17:47:24 17:47:24 CMAKE_BUILD_TYPE {code} And subsequently in the --build step, the --config is unused. Resulting in a Debug-by-default build on windows. --config Debug or- -config Release (depending on buildType should be added to the --build phase for windows (and CMAKE_BUILD_TYPE should not be used for visual studio generator) The current workaround to this is adding --config Debug/Release explicitly in the steps: {code:java} steps: [[args: '--config Debug', withCmake: true]] {code} Which of course is less than ideal if the buildType property is available. |
Description |
Original:
I have created a Jenkins pipeline that covers both windows and linux. However it appears that cmakeBuild does not use buildType correctly for visual studio For Linux is correctly adds -DCMAKE_BUILD_TYPE=Debug or Release in the configure step However for windows the CMAKE_BUILD_TYPE variable is ignored: {code:java} 17:47:24 Manually-specified variables were not used by the project: 17:47:24 17:47:24 CMAKE_BUILD_TYPE {code} And subsequently in the --build step, the --config is unused. Resulting in a Debug-by-default build on windows. --config Debug or- -config Release (depending on buildType should be added to the --build phase for windows (and CMAKE_BUILD_TYPE should not be used for visual studio generator) The current workaround to this is adding --config Debug/Release explicitly in the steps: {code:java} steps: [[args: '--config Debug', withCmake: true]] {code} Which of course is less than ideal if the buildType property is available. |
New:
I have created a Jenkins pipeline that covers both windows and linux. However it appears that cmakeBuild does not use buildType correctly for visual studio For Linux is correctly adds -DCMAKE_BUILD_TYPE=Debug or Release in the configure step However for windows the CMAKE_BUILD_TYPE variable is ignored: {code:java} 17:47:24 Manually-specified variables were not used by the project: 17:47:24 17:47:24 CMAKE_BUILD_TYPE {code} And subsequently in the --build step, the --config is unused. Resulting in a Debug-by-default build with the visual studio generator. --config Debug or- -config Release (depending on buildType should be added to the --build phase for windows (and CMAKE_BUILD_TYPE should not be used for visual studio generator) The current workaround to this is adding --config Debug/Release explicitly in the steps: {code:java} steps: [[args: '--config Debug', withCmake: true]] {code} Which of course is less than ideal if the buildType property is available. |