linux – 在makefile中处理管道及其退出状态的最佳方式

linux – 在makefile中处理管道及其退出状态的最佳方式

如果命令失败,例如 gcc,它将退出… gccgcc: fatal error: no input filescompilation terminated.make: *** [main.o] Error 4 但是,如果我有一个管道,则管道中最后一个命令的退出状态将被采用.例如,gcc |猫不会因为猫成功而失败. 我知道整个管道的退出代码存