I have 24-core poudriere build server that does daily builds and is great for detecting parallel build problems. Occasionally it fails to build net/dhcp6 and when it does the build log shows three attempts to rename y.tab.c to cfparse.c but only the two succeed (see attached).
I believe the problem is that the Makefile has an explicit (but unnecessary dependency) for y.tab.h. When a parallel make happens to build y.tab.h and cftoken.c at the same time one of these fails.
Clearly y.tab.h will be created as a side effect of running flex on cftoken.l to create cftoken.c and only cftoken.c includes y.tab.h so my patch removes the unnecessary dependency.
I also submitted the attached patch to upstream back in February:
Created attachment 182059 [details]
Created attachment 182060 [details]
Poudriere build log showing failure to build