help-make
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

target clean and prerquisites *.d


From: Wolfram Ditzer
Subject: target clean and prerquisites *.d
Date: Fri, 04 Feb 2005 16:25:22 +0100
User-agent: Mozilla Thunderbird 0.5 (Windows/20040207)

Hello,

Is there a way to prevent Make from checking Makfiles when inluding them with "include"?

I´m using the rule from GNU Make documentation to create prerequsites for my source files:

%.d: %.cc
       @set -e; rm -f $@; \
        $(CC) -M $(CPPFLAGS) $< > address@hidden; \
        sed 's,\($*\)\.o[ :]*,\1.o $@ : ,g' < address@hidden > $@; \
        rm -f address@hidden


In my Makefiles I  include the *.d files:

depFile := $(whitespace *.d)
include $(depFile)

I edited my yource files, I renamed a source file from manager.h to dbmanager.h
Now I´m runnig make clean to clean object files , etc. and I get

make  clean
make: *** No rule to make target `../dbutil/manager.h', needed by `db.d'. Stop.

I think Make runs the target db.d after including db.d. So it tries to update the db.d an detects missing file manager.h.

How can I prevent this?

Is there a way to first build manager.o before updateing all prerquisite files when I do "make manager.o"?





reply via email to

[Prev in Thread] Current Thread [Next in Thread]