All,
I use the following rules to generate dependency automatically
%.P : %.cpp
$(QUIET_MM)rm -f $@; \
$(CPP) -M $(CPPFLAGS) $(CXXFLAGS) $(INCLUDES) $< > $...@.$$$$; \
sed -e 's,\($*\)\.o[ :]*,$@ \1.o : ,g' < $...@.$$$$ > $@; \
rm -f $...@.$$$$
then include it
When one dependency header file (it is written to .P file) is deleted
as it is not used,make doesn't work
l...@linux01:~/demo$ ./make demo.o
make: *** No rule to make target `../../a.h', needed by `demo.o'. Stop.
I guess make isn't happy when dependency is missing
Thanks for your help in advance
Thanks
Lynn
_______________________________________________
Help-make mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-make