set skip_globs [jobdb::read-runvar $flight $job skip_testids]
set nh [need-hosts/$jobinfo(recipe)]
- if {![string compare $nh BUILD]} {
+ if {[regsub {^BUILD_} $nh "" need_build_host]} {
set need_xen_hosts {}
- set need_build_host 1
} else {
set need_xen_hosts $nh
- set need_build_host 0
+ set need_build_host {}
}
set nested_layers_hosts {}
eval run-ts broken = ts-hosts-allocate + $need_xen_hosts
}
- if {$need_build_host} { catching-otherwise broken allocate-build-host }
+ if {[llength $need_build_host]} {
+ catching-otherwise broken { allocate-build-host $need_build_host }
+ }
if {$ok} { setstatus running }
if {$ok} { set syslog [spawn-ts broken = | ts-syslog-server] }
- if {$need_build_host} { catching-otherwise broken prepare-build-host }
+ if {[llength $need_build_host]} {
+ catching-otherwise broken {
+ prepare-build-host-[string tolower $need_build_host]
+ }
+ }
per-host-ts broken host-install/@(*) ts-host-install-twice
set need_xen_hosts [lunappend nested_layers_hosts]
}
- if {$need_build_host && !$ok} {
+ if {[llength $need_build_host] && !$ok} {
run-ts !broken capture-logs ts-logs-capture + host
}
if {$ok} { setstatus pass }
- if {$need_build_host && $ok} { jobdb::preserve-task 90 }
+ if {[llength $need_build_host] && $ok} { jobdb::preserve-task 90 }
if {!$ok} {
jobdb::logputs stdout "job not ok"
#---------- builds ----------
-proc need-hosts/build {} { return BUILD }
-proc need-hosts/build-kern {} { return BUILD }
-proc need-hosts/build-libvirt {} { return BUILD }
-proc need-hosts/build-rumprun {} { return BUILD }
-proc need-hosts/build-xtf {} { return BUILD }
+proc need-hosts/build {} { return BUILD_LINUX }
+proc need-hosts/build-kern {} { return BUILD_LINUX }
+proc need-hosts/build-libvirt {} { return BUILD_LINUX }
+proc need-hosts/build-rumprun {} { return BUILD_LINUX }
+proc need-hosts/build-xtf {} { return BUILD_LINUX }
proc run-job/build {} {
run-ts . = ts-xen-build
run-ts . = ts-xtf-build
}
-proc allocate-build-host {} {
+proc allocate-build-host {ostype} {
global jobinfo
run-ts broken = ts-hosts-allocate + host
}
-proc prepare-build-host {} {
+proc prepare-build-host-linux {} {
global jobinfo
run-ts broken host-install(*) ts-host-install-twice
run-ts . host-build-prep ts-xen-build-prep
}
-proc need-hosts/coverity {} { return BUILD }
+proc need-hosts/coverity {} { return BUILD_LINUX }
proc run-job/coverity {} {
run-ts . = ts-coverity-build + host
run-ts . = ts-coverity-upload + host