I got a report that the output / logfile of the CGT is unusable/readable when using parallel compilation (-j<n>) in make. This issue does not occur when using gcc.
Problem is, that CGT is not doing a line buffered output. It makes a system call for every single character. Output from a strace -ff -e write cl6x <flags> sourcefile.c
[pid 6915] write(2, "\"", 1") = 1
[pid 6915] write(2, "/", 1/) = 1
[pid 6915] write(2, "v", 1v) = 1
[pid 6915] write(2, "a", 1a) = 1
[pid 6915] write(2, "r", 1r) = 1
[pid 6915] write(2, "/", 1/) = 1
[pid 6915] write(2, "f", 1f) = 1
[pid 6915] write(2, "p", 1p) = 1
[pid 6915] write(2, "w", 1w) = 1
[pid 6915] write(2, "o", 1o) = 1
[pid 6915] write(2, "r", 1r) = 1
[pid 6915] write(2, "k", 1k) = 1
[pid 6915] write(2, "/", 1/) = 1
[pid 6915] write(2, "d", 1d) = 1
If there is a second cgt process, which is also printing something to stdout, the output is jammed => unreadable.
Are there any options for enabling line buffered output with CGT to work this around?
-Matti