On 11/28/20 12:28 PM, Simon Ruderich wrote: > blhc uses a few heuristics to detect lines with (possible) > compiler commands to prevent false negatives. Lines containing > `gcc` and similar are flagged. In this case the CC= environment > variable triggers this. Then blhc looks for the actual build > command and its flags. Here the quote after -D_FORTIFY_SOURCE=2 > is the problem because blhc requires a space after each flag. I > know this handling is not perfect but parsing arbitrary shell > commands is difficult.
I see. Thanks for your explanation! I'm aware of the complexity and difficulty of parsing arbitrary shell commands, so it's not a problem at all that some false positives (and negatives) exist. I just found this particular example confusing because blhc seemed to recognize the compiler command in the environment variable assignment, but not the flags on the same line, which seemed weird to me. Thanks again for having a look at this! Fabian