builder: run builder.test using a more robust process descriptor

db4
Eduardo Cavazos 2008-02-18 09:01:31 -06:00
parent 957160ad73
commit fa5b621257
2 changed files with 20 additions and 13 deletions

View File

@ -88,7 +88,19 @@ VAR: stamp
20 minutes>ms >>timeout 20 minutes>ms >>timeout
>desc ; >desc ;
: builder-test ( -- desc ) { factor-binary "-run=builder.test" } to-strings ; ! : builder-test ( -- desc ) { factor-binary "-run=builder.test" } to-strings ;
: builder-test-cmd ( -- cmd )
{ factor-binary "-run=builder.test" } to-strings ;
: builder-test ( -- desc )
<process*>
builder-test-cmd >>arguments
+closed+ >>stdin
"../test-log" >>stdout
+stdout+ >>stderr
45 minutes>ms >>timeout
>desc ;
! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@ -125,9 +137,11 @@ SYMBOL: build-status
bootstrap [ "Bootstrap error" print "../boot-log" cat ] run-or-bail bootstrap [ "Bootstrap error" print "../boot-log" cat ] run-or-bail
[ builder-test try-process ] ! [ builder-test try-process ]
[ "Builder test error" print throw ] ! [ "Builder test error" print throw ]
recover ! recover
builder-test [ "Test error" print "../test-log" cat ] run-or-bail
"Boot time: " write "../boot-time" eval-file milli-seconds>time print "Boot time: " write "../boot-time" eval-file milli-seconds>time print
"Load time: " write "../load-time" eval-file milli-seconds>time print "Load time: " write "../load-time" eval-file milli-seconds>time print

View File

@ -84,10 +84,3 @@ TUPLE: process* arguments stdin stdout stderr timeout ;
USING: bootstrap.image bootstrap.image.download io.streams.null ; USING: bootstrap.image bootstrap.image.download io.streams.null ;
: retrieve-image ( -- ) [ my-arch download-image ] with-null-stream ; : retrieve-image ( -- ) [ my-arch download-image ] with-null-stream ;
! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
: copy-image ( -- )
"../../factor/" my-arch boot-image-name append
my-arch boot-image-name
copy-file ;