Suppress echo of command invocation in makefile?

前端 未结 4 754
迷失自我
迷失自我 2021-01-30 06:13

I wrote a program for an assignment which is supposed to print its output to stdout. The assignment spec requires the creation of a Makefile which when invoked as make run

4条回答
  •  慢半拍i
    慢半拍i (楼主)
    2021-01-30 06:29

    The effect of preceding the command with an @ can be extended to a section by extending the command using a trailing backslash on the line. If a .PHONY command is desired to suppress output one can begin the section with:

    @printf "..."
    

提交回复
热议问题