STRAIN(1M) STRAIN(1M)
strain - extract errors from build log files.
strain [ -h | -s ] [ -w ] [ -c context ] <logfile>
strain is used to extract error messages from a build log. It displays
the error and a certain amount of context around it. strain can work on
an arbitrary input, but works best with input that has special markers
known to strain. For large build logs, strain is an effective tool in
determining build success or failure.
strain works by folding the log file into 512 character lines and feeding
these lines through a nawk(1) script which looks for known error messages
patterns. When strain encounters an error, it simply saves that line
number and continues scanning. If strain hits either a marker or
accumulates context lines, it dumps the line in errors and the
surrounding context. Markers are lines beginning with: @<,@>,===,
-c accumulate context lines before dumping any errors. Default is 15.
-h show highlights only. This option prints out every line that begins
with :-( (Mk's "subsystem build failure" identifier) or = (the
"subsystem build begin" identifier printed by Mk and some
makefiles).
-s provide a summary list of directories with errors before the strain
output.
-w show warning messages, in addition to error messages.
The -h and -s options are mutually exclusive.
nawk(1), fold(1), makewrapper(1)
strain's algorithm for finding bugs is simply a list of patterns to
search for. New tools often report errors in a way that strain doesn't
understand.
PPPPaaaaggggeeee 1111 [ Back ]
|