Package hudson.plugins.cmake
Class CmakeTool
java.lang.Object
hudson.model.AbstractDescribableImpl<ToolInstallation>
hudson.tools.ToolInstallation
hudson.plugins.cmake.CmakeTool
- All Implemented Interfaces:
ExtensionPoint,Describable<ToolInstallation>,EnvironmentSpecific<CmakeTool>,NodeSpecific<CmakeTool>,Serializable
public class CmakeTool
extends ToolInstallation
implements NodeSpecific<CmakeTool>, EnvironmentSpecific<CmakeTool>
Information about Cmake installation. A CmakeTool is used to select between
different installations of cmake, as in "cmake2.6.4" or "cmake2.8.12".
- Author:
- Martin Weber
- See Also:
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class hudson.tools.ToolInstallation
ToolInstallation.ToolConverterNested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionCmakeTool(String name, String home, List<? extends ToolProperty<?>> properties) Constructor for CmakeTool. -
Method Summary
Modifier and TypeMethodDescriptionvoidbuildEnvVars(EnvVars env) Overwritten to add the path to cmake`s bin directory, if tool was downloaded.forEnvironment(EnvVars environment) forNode(Node node, TaskListener log) getAbsoluteCommand(Node node, String basename) Gets the absolute file system path on the specified node with the basename appended.static voidonLoaded()Creates a default tool installation if needed.Methods inherited from class hudson.tools.ToolInstallation
all, getHome, getName, getProperties, readResolve, toString, translate, translate, translateFor, writeReplaceMethods inherited from class hudson.model.AbstractDescribableImpl
getDescriptor
-
Field Details
-
DEFAULT
Tool name of the default tool (usually found on the executable search path). Do not use: Exposed here only for testing purposes.- See Also:
-
-
Constructor Details
-
CmakeTool
@DataBoundConstructor public CmakeTool(String name, String home, List<? extends ToolProperty<?>> properties) Constructor for CmakeTool.- Parameters:
name- Tool name (for example, "cmake2.6.4" or "cmake2.8.12")home- the parent directory of thecmaketool from the installation. This is used to determine the file system path of any of the tools of the cmake suite (cmake/cpack/ctest).properties-Listof properties for this tool
-
-
Method Details
-
getAbsoluteCommand
Gets the absolute file system path on the specified node with the basename appended. Takes the node specific directory separators into account when constructing the path.
Should be invoked afterforNode(Node, TaskListener)was called.- Parameters:
node- Node that this tool is used in.basename- the basename of the command to run (cmake, cpack or ctest).- Returns:
- the absolute file system path on the node or just the basename,
if
ToolInstallation.getHome()returns null
-
buildEnvVars
Overwritten to add the path to cmake`s bin directory, if tool was downloaded.- Overrides:
buildEnvVarsin classToolInstallation
-
forNode
- Specified by:
forNodein interfaceNodeSpecific<CmakeTool>- Throws:
IOExceptionInterruptedException
-
forEnvironment
- Specified by:
forEnvironmentin interfaceEnvironmentSpecific<CmakeTool>
-
onLoaded
Creates a default tool installation if needed. Uses "cmake" or migrates data from previous versions
-