Hello Brian, * [EMAIL PROTECTED] wrote on Fri, Oct 03, 2008 at 12:04:04AM CEST: > I'm trying to create an "archive" (copy of the project) as follows: > The top level Makefile creates the directory and copies some stuff > into it. Then it recurses into subdirectories, and tells them to add > their own files to the directory it created.
Sounds like you're more or less doing manually what Automake provides with its 'distdir' rule. > If the subdirectory > Makefiles decide to actually add anything to the directory, they touch > it to make it up to date. That's the problem, AFAICS: you cannot have several rules updating the same file, that will confuse make. Whenever you can't express the dependencies between files as a directed tree, you have to either use stamp files, and/or reinvoke make within a rule to let it recompute the set of needed rules based on updated timestamps. For example, post-update actions can typically be realized like this: target: deps... update_target $(MAKE) post-action-for-target Hope that helps to get you going (otherwise please report back). Cheers, Ralf