Tees stdout from make to a file (in a way that doesn't suppress an error exit from make from failing the build), and runs a sed script over that file which looks for a list of failed modules, outputs it to ensure it isn't lost in the build output, and exits with an error code to cause the build to fail.