2015-07-09 12:45:56 -04:00
|
|
|
USING: accessors bootstrap.image fry grouping io.files io.pathnames kernel
|
|
|
|
sequences system tools.deploy.backend tools.image-analyzer tools.test ;
|
|
|
|
IN: tools.image-analyzer.tests
|
|
|
|
|
2015-12-13 01:54:04 -05:00
|
|
|
: boot-image-path ( arch -- path )
|
2015-07-09 20:23:16 -04:00
|
|
|
boot-image-name resource-path ;
|
|
|
|
|
2015-07-09 12:45:56 -04:00
|
|
|
: ?make-image ( arch -- )
|
2015-12-13 01:54:04 -05:00
|
|
|
dup boot-image-path exists? [ drop ] [ make-image ] if ;
|
2015-07-09 12:45:56 -04:00
|
|
|
|
|
|
|
: loadable-images ( -- images )
|
2015-08-12 12:08:24 -04:00
|
|
|
image-names cpu name>> '[ _ tail? ] filter ;
|
2015-07-09 12:45:56 -04:00
|
|
|
|
|
|
|
{ t } [
|
|
|
|
loadable-images [ [ ?make-image ] each ] [
|
|
|
|
[
|
2015-12-13 01:54:04 -05:00
|
|
|
boot-image-path load-image header>> code-size>>
|
2015-07-09 12:45:56 -04:00
|
|
|
] map [ 0 = ] all?
|
|
|
|
] bi
|
|
|
|
] unit-test
|