1 ! Copyright (C) 2008 Eduardo Cavazos, Slava Pestov.
2 ! See http://factorcode.org/license.txt for BSD license.
3 USING: accessors arrays calendar combinators.short-circuit
4 continuations debugger http.client io.directories io.files
5 io.launcher io.pathnames kernel make mason.common mason.config
6 mason.platform mason.report namespaces sequences ;
10 gnu-make platform 2array ;
12 : download-dlls ( -- )
13 target-os get "winnt" = [
14 "http://factorcode.org/dlls/"
15 target-cpu get "x86.64" = [ "64/" append ] when
16 [ "freetype6.dll" append ]
17 [ "zlib1.dll" append ] bi
27 "../compile-log" >>stdout
32 : builds-factor-image ( -- img )
33 builds/factor boot-image-name append-path ;
36 builds-factor-image "." copy-file-into
37 builds-factor-image "factor" copy-file-into ;
41 "-i=" boot-image-name append
50 "../boot-log" >>stdout
56 : test-cmd ( -- cmd ) { "./factor" "-run=mason.test" } ;
63 "../test-log" >>stdout
69 : return-with ( obj -- ) return-continuation get continue-with ;
71 : build-clean? ( -- ? )
73 [ load-everything-vocabs-file eval-file empty? ]
74 [ test-all-vocabs-file eval-file empty? ]
75 [ help-lint-vocabs-file eval-file empty? ]
76 [ compiler-errors-file eval-file empty? ]
81 return-continuation set
85 [ make-vm ] [ compile-failed-report status-error return-with ] recover
86 [ boot ] [ boot-failed-report status-error return-with ] recover
87 [ test ] [ test-failed-report status-error return-with ] recover
91 build-clean? status-clean status-dirty ? return-with