#---------------------------------------------- # 0-th makefile example: basic control flow #---------------------------------------------- #--------------------------------------------------------------------------- # A leading '@' means "don't print this command". # Note: You can invoke make with the -s switch (for "silent running"), or # you can use the .SILENT: pseudo-target (deprecated), or you can # use '@'. #--------------------------------------------------------------------------- #.SILENT: #-----!!!------------------------------------------------- # NOTE: action lines must begin with TAB (not spaces) #-----!!!------------------------------------------------- firstTarget: echo at firstTarget touch firstTarget secondTarget: firstTarget @# leading '@' means "do not print out this line before executing" @echo at secondTarget touch secondTarget thirdTarget: secondTarget echo at thirdTarget touch thirdTarget #------------------------------------------------------ # 'clean' is a target in pretty much all makefiles. # You have to write it, but by convention it deletes # all the files generated in processing all the # make targets. #------------------------------------------------------ clean: rm -f firstTarget secondTarget thirdTarget