假设我在Makefile
中有以下规则。Makefile |头文件中包含的另一个头文件的依赖关系
test.o: test.cpp foo.h
g++ -c -o test.o test.cpp
现在假设foo.h
包括bar.h
,如下所示。
user $ head -n 5 foo.h
#include"bar.h"
/*
.
.
*/
user $
请问test.o
重新建造是否有bar.h
什么变化?
或者我应该特别提到在规则如下bar.h
:
test.o: test.cpp foo.h bar.h
g++ -c -o test.o test.cpp