ref: da04ee7b0352fe9d2605481d643ffff09588f99b
dir: /mbld/types.myr/
use std pkg bld = type build = struct /* build state */ basedir : byte[:] bldfile : byte[:] curdir : byte[:] built : std.htab(byte[:], bool)# /* set of targets built in this run */ tags : std.htab(byte[:], (int, int, int))# /* build params */ all : byte[:][:] /* targets in reverse topological order */ targs : std.htab(byte[:], targ)# /* name => target mapping */ tdeps : std.htab(byte[:], byte[:][:]) /* targname => depname[:][:] */ gensrc : std.htab(byte[:], cmdtarg#)# /* generated => generator mapping */ prefix : byte[:] system : byte[:] arch : byte[:] ;; type targ = union `Bin myrtarg# `Lib myrtarg# `Gen cmdtarg# `Cmd cmdtarg# `Man mantarg# `Data datatarg# ;; type myrtarg = struct file : byte[:] line : int islib : bool istest : bool dir : byte[:] name : byte[:] inputs : byte[:][:] libdeps : (byte[:], byte[:], byte[:])[:] /* dir, lib, targname */ tstdeps : (byte[:], byte[:], byte[:])[:] /* dir, lib, targname */ install : bool runtime : byte[:] incpath : byte[:][:] tags : byte[:][:] ldscript : byte[:] ;; type cmdtarg = struct dir : byte[:] out : byte[:][:] cmd : byte[:][:] deps : byte[:][:] tags : byte[:][:] durable : bool /* we can have multiple outputs, but we only want to run once for each */ done : bool istest : bool ;; type mantarg = struct dir : byte[:] tags : byte[:][:] pages : byte[:][:] ;; type datatarg = struct dir : byte[:] name : byte[:] tags : byte[:][:] path : byte[:] blobs : byte[:][:] ;; type depgraph = struct deps : std.htab(byte[:], byte[:][:])# libs : std.htab(byte[:], byte[:][:])# input : std.htab(byte[:], byte[:])# sources : std.htab(byte[:], bool)# updated : std.htab(byte[:], bool)# seen : std.htab(byte[:], bool)# done : std.htab(byte[:], bool)# /* used for linking C */ extlibs : byte[:][:] cflags : std.htab(byte[:], byte[:][:])# dynamic : bool ;; ;;