Makefile target dependency to generated files
问题 I have a question regarding the behavior of Make when running targets that are dependent on generated files. Given the source tree and Makefile below, when I run this it takes two runs to complete the "build" even though everything was generated on the first run. $ ls -R .: bar foo Makefile Makefile all: foobar work: mkdir -p work work/foo: work foo cp foo work/foo work/bar: work bar cp bar work/bar foobar: work/foo work/bar make $ make mkdir -p work cp foo work/foo cp bar work/bar $ ls -R .: