On Sat, Oct 25, 2008 at 09:33:48AM -0500, Peng Yu wrote:
> Hi,
> 
> Suppose there are many subdirectories in a directory. The sub dirs all
> have working makefiles.
> 
> 'make -j3' in the parent dir would parallel make all directories. But
> 'make clean -j3' could not. The problem is that I don't know how to
> clean each directory as well as deleting the file '.d'.
> 
> Can somebody let me know how to do it?

Try to study the following sample:
SUBDIRS := b c d e f

.PHONY: $(SUBDIRS)

all: $(SUBDIRS)

$(SUBDIRS):
        @sleep 1; echo rm -f $@/*

See how make is used and not a shell script to
visit each directory.
You should be able to tweak your makefile to use the
same way of doing it.

        Sam


_______________________________________________
Help-make mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-make

Reply via email to