Home | History | Annotate | Download | only in unit-tests
History log of /src/usr.bin/make/unit-tests/meta-output.mk
RevisionDateAuthorComments
 1.5  05-Aug-2025  sjg meta-output.mk diff output

We construct output such that it should match what we
can extract from output.meta, so diff the two.
This way the test cannot pass if meta.c is capturing
something inaccurately - other than the trailing newline.
 1.4  04-Aug-2025  sjg Use printf rather than echo -n
 1.3  04-Aug-2025  sjg echo.inc make ECHO_SCRIPT reusable
 1.2  04-Aug-2025  sjg meta-output.mk: Allow for echo that does not support -n

On latest Darwin, /bin/sh builtin echo does not do -n

There will be others, so test if echo -n works and adjust.

Capture only the command output from the meta file so
that results can be consistent whether echo -n works or not.
 1.1  03-Aug-2025  sjg make: ensure output captured in meta file is accurate

In CollectOutput() a newline before the end of job->outBuf
results in a short write to stdout, but meta_job_output()
was recording the entire string in the meta file, so on
next call the left overs would be duplicated in the meta file.

Pass a length to meta_job_output() if it should only report part of
the data in meta file.

RSS XML Feed