[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Fixing a Target Order based on the requested target?
From: |
Yannick Koehler |
Subject: |
Re: Fixing a Target Order based on the requested target? |
Date: |
Fri, 23 Mar 2007 08:30:38 -0400 |
2007/3/21, Dave Korn <address@hidden>:
Use a sentinel?
.PHONY: a b c d e
a:
@echo "Target $@ is Done"
@touch .e-ok
b:
@echo "Target $@ is Done"
@touch .e-ok
c:
@echo "Target $@ is Done"
@touch .e-ok
d:
@echo "Target $@ is Done"
@touch .e-ok
e: .e-ok
@echo "Target $@ is Done"
.e-ok:
@echo "You must build one of a-d before you can build e"
@exit -1
cheers,
DaveK
Thanks for this idea, it looks like a real step forward for my issue.
Yet, now that this works, I have found another problem.
If someone do
make a b e
the system build e before b is completed. But e doesn`t detect b as
it has not been built before it...
So the sentinel make sure that e is built only after at least one of a
b c d is built but it doesn`t garantee that e is the last one built
which is also another need I have.
--
Yannick Koehler
email: address@hidden
blog: http://yannick.koehler.name