Index: Jenkinsfile
===================================================================
--- Jenkinsfile	(revision 47b32352e9c8cd9b32f41db9c140fabdff4585b3)
+++ Jenkinsfile	(revision 7e288c44c1d1885b376034d85b2c51bdc9f5088d)
@@ -4,6 +4,4 @@
 // Main loop of the compilation
 //===========================================================================================================
-set -x
-
 node ('master'){
 
@@ -13,14 +11,4 @@
 
 	stage_name 		= ''
-
-	compiler 		= null
-	arch_name 		= ''
-	architecture 	= ''
-
-	do_alltests		= false
-	do_benchmark	= false
-	do_doc		= false
-	do_publish		= false
-	do_sendemail	= true
 
 	builddir = pwd tmp: true
@@ -72,5 +60,5 @@
 	finally {
 		//Send email with final results if this is not a full build
-		if( do_sendemail ) {
+		if( !params.Silent ) {
 			echo 'Notifying users of result'
 			email(currentBuild.result, log_needed, bIsSandbox)
@@ -150,24 +138,15 @@
 		]])
 
-	compiler 		= compiler_from_params( params.Compiler )
-	arch_name		= params.Architecture
-	architecture 	= architecture_from_params( arch_name )
-
-	do_alltests		= (params.RunAllTests == 'true')
-	do_benchmark	= (params.RunBenchmark == 'true')
-	do_doc		= (params.BuildDocumentation == 'true')
-	do_publish		= (params.Publish == 'true')
-	do_sendemail	= ! (params.Silent == 'true')
-
-	echo params.RunAllTests.getClass().toString();
+	params.Compiler	  = compiler_from_params( params.Compiler )
+	params.Architecture = architecture_from_params( params.Architecture )
 
 	collect_git_info()
 
-	def full = do_alltests ? " (Full)" : ""
-	currentBuild.description = "${compiler.cc_name}:${arch_name}${full}"
-
-	echo """Compiler 	         : ${ compiler.cc_name } (${ compiler.cpp_cc }/${ compiler.cfa_cc })
-Architecture            : ${ arch_name }
-Arc Flags               : ${ architecture }
+	def full = params.RunAllTests ? " (Full)" : ""
+	currentBuild.description = "${ params.Compiler.cc_name }:${ params.Architecture.name }${full}"
+
+	echo """Compiler 	         : ${ params.Compiler.cc_name } (${ params.Compiler.cpp_cc }/${ params.Compiler.cfa_cc })
+Architecture            : ${ params.Architecture.name }
+Arc Flags               : ${ params.Architecture.flags }
 Run All Tests           : ${ params.RunAllTests.toString() }
 Run Benchmark           : ${ params.RunBenchmark.toString() }
@@ -235,11 +214,22 @@
 }
 
+//Description of an architecture (Must be serializable since pipelines are persistent)
+class CC_Desc implements Serializable {
+	public String name
+	public String flags
+
+	CC_Desc(String name, String flags) {
+		this.name  = name
+		this.flags = flags
+	}
+}
+
 def architecture_from_params( arch ) {
 	switch( arch ) {
 		case 'x64':
-			return '--host=x86_64'
+			return new CC_Desc('x64', '--host=x86_64')
 		break
 		case 'x86':
-			return '--host=i386'
+			return new CC_Desc('x86', '--host=i386')
 		break
 		default :
@@ -282,5 +272,5 @@
 			//Also specify the compiler by hand
 			targets=""
-			if(do_alltests) {
+			if( params.RunAllTests ) {
 				targets="--with-target-hosts='host:debug,host:nodebug'"
 			} else {
@@ -288,5 +278,5 @@
 			}
 
-			sh "${srcdir}/configure CXX=${compiler.cpp_cc} ${architecture} ${targets} --with-backend-compiler=${compiler.cfa_cc} --quiet"
+			sh "${srcdir}/configure CXX=${params.Compiler.cpp_cc} ${params.Architecture.flags} ${targets} --with-backend-compiler=${params.Compiler.cfa_cc} --quiet"
 
 			//Compile the project
@@ -301,5 +291,5 @@
 		dir (builddir) {
 			//Run the tests from the tests directory
-			if ( do_alltests ) {
+			if ( params.RunAllTests ) {
 				sh 'make --no-print-directory -C tests all-tests debug=yes'
 				sh 'make --no-print-directory -C tests all-tests debug=no '
@@ -315,9 +305,9 @@
 	build_stage('Benchmark') {
 
-		if( !do_benchmark ) return
+		if( !params.RunBenchmark ) return
 
 		dir (builddir) {
 			//Append bench results
-			sh "make --no-print-directory -C benchmark jenkins githash=${gitRefNewValue} arch=${arch_name} | tee ${srcdir}/bench.json"
+			sh "make --no-print-directory -C benchmark jenkins githash=${gitRefNewValue} arch=${params.Architecture} | tee ${srcdir}/bench.json"
 		}
 	}
@@ -327,5 +317,5 @@
 	build_stage('Documentation') {
 
-		if( !do_doc ) return
+		if( !params.BuildDocumentation ) return
 
 		dir ('doc/user') {
@@ -342,5 +332,5 @@
 	build_stage('Publish') {
 
-		if( !do_publish ) return
+		if( !params.Publish ) return
 
 		//Then publish the results
