Index: Jenkins/tools.groovy
===================================================================
--- Jenkins/tools.groovy	(revision 0797198102ef8bcd87ed48121d74d91e67ac480b)
+++ Jenkins/tools.groovy	(revision 0797198102ef8bcd87ed48121d74d91e67ac480b)
@@ -0,0 +1,22 @@
+#!groovy
+
+
+// For skipping stages
+import org.jenkinsci.plugins.pipeline.modeldefinition.Utils
+
+// Global for the stage name
+StageName = ''
+
+// wrapper around stage declaretion to be more verbose
+// and allow showing as skipped in the UI
+def BuildStage(String name, boolean run, Closure block ) {
+	StageName = name
+	echo " -------- ${StageName} -------- "
+	if(run) {
+		stage(name, block)
+	} else {
+		stage(name) { Utils.markStageSkippedForConditional(STAGE_NAME) }
+	}
+}
+
+return this;
Index: Jenkinsfile
===================================================================
--- Jenkinsfile	(revision 8e655f7c33374214f8eb899c9053905380e45e6f)
+++ Jenkinsfile	(revision 0797198102ef8bcd87ed48121d74d91e67ac480b)
@@ -2,7 +2,4 @@
 
 import groovy.transform.Field
-
-// For skipping stages
-import org.jenkinsci.plugins.pipeline.modeldefinition.Utils
 
 //===========================================================================================================
@@ -15,5 +12,5 @@
 	SrcDir    = pwd tmp: false
 	Settings  = null
-	StageName = ''
+	Tools     = null
 
 	// Local variables
@@ -66,5 +63,5 @@
 
 		//Store the result of the build log
-		currentBuild.result = "${StageName} FAILURE".trim()
+		currentBuild.result = "${tools.StageName} FAILURE".trim()
 	}
 
@@ -85,5 +82,5 @@
 //===========================================================================================================
 def clean() {
-	build_stage('Cleanup', true) {
+	Tools.BuildStage('Cleanup', true) {
 		// clean the build by wipping the build directory
 		dir(BuildDir) {
@@ -95,5 +92,5 @@
 //Compilation script is done here but environnement set-up and error handling is done in main loop
 def checkout() {
-	build_stage('Checkout', true) {
+	Tools.BuildStage('Checkout', true) {
 		//checkout the source code and clean the repo
 		final scmVars = checkout scm
@@ -108,5 +105,5 @@
 	debug = true
 	release = Settings.RunAllTests || Settings.RunBenchmark
-	build_stage('Build : configure', true) {
+	Tools.BuildStage('Build : configure', true) {
 		// Configure must be run inside the tree
 		dir (SrcDir) {
@@ -136,5 +133,5 @@
 	}
 
-	build_stage('Build : cfa-cpp', true) {
+	Tools.BuildStage('Build : cfa-cpp', true) {
 		// Build outside of the src tree to ease cleaning
 		dir (BuildDir) {
@@ -147,5 +144,5 @@
 	}
 
-	build_stage('Build : libcfa(debug)', debug) {
+	Tools.BuildStage('Build : libcfa(debug)', debug) {
 		// Build outside of the src tree to ease cleaning
 		dir (BuildDir) {
@@ -154,5 +151,5 @@
 	}
 
-	build_stage('Build : libcfa(nodebug)', release) {
+	Tools.BuildStage('Build : libcfa(nodebug)', release) {
 		// Build outside of the src tree to ease cleaning
 		dir (BuildDir) {
@@ -161,5 +158,5 @@
 	}
 
-	build_stage('Build : install', true) {
+	Tools.BuildStage('Build : install', true) {
 		// Build outside of the src tree to ease cleaning
 		dir (BuildDir) {
@@ -171,5 +168,5 @@
 def test() {
 	try {
-		build_stage('Test: short', !Settings.RunAllTests) {
+		Tools.BuildStage('Test: short', !Settings.RunAllTests) {
 			dir (BuildDir) {
 				//Run the tests from the tests directory
@@ -178,5 +175,5 @@
 		}
 
-		build_stage('Test: full', Settings.RunAllTests) {
+		Tools.BuildStage('Test: full', Settings.RunAllTests) {
 			dir (BuildDir) {
 					//Run the tests from the tests directory
@@ -196,5 +193,5 @@
 
 def benchmark() {
-	build_stage('Benchmark', Settings.RunBenchmark) {
+	Tools.BuildStage('Benchmark', Settings.RunBenchmark) {
 		dir (BuildDir) {
 			//Append bench results
@@ -205,5 +202,5 @@
 
 def build_doc() {
-	build_stage('Documentation', Settings.BuildDocumentation) {
+	Tools.BuildStage('Documentation', Settings.BuildDocumentation) {
 		dir ('doc/user') {
 			make_doc()
@@ -217,5 +214,5 @@
 
 def publish() {
-	build_stage('Publish', true) {
+	Tools.BuildStage('Publish', true) {
 
 		if( Settings.Publish && !Settings.RunBenchmark ) { echo 'No results to publish!!!' }
@@ -506,6 +503,10 @@
 		]])
 
-	// It's unfortunate but it looks like we need to checkout the entire repo just to get the pretty git printer
+	// It's unfortunate but it looks like we need to checkout the entire repo just to get
+	// - the pretty git printer
+	// - Jenkins.tools
 	checkout scm
+
+	Tools = load "Jenkins/tools.groovy"
 
 	final settings = new BuildSettings(params, env.BRANCH_NAME)
@@ -515,14 +516,4 @@
 
 	return settings
-}
-
-def build_stage(String name, boolean run, Closure block ) {
-	StageName = name
-	echo " -------- ${StageName} -------- "
-	if(run) {
-		stage(name, block)
-	} else {
-		stage(name) { Utils.markStageSkippedForConditional(STAGE_NAME) }
-	}
 }
 
