I've been looking at the manual about pattern rules. In an earlier message I stated that I was building 72k + targets. Paul suggested that I look at Pattern rules.
Here's the problem I have now that I'm trying to correct. EX: CFLAGS := -Ddogs -Dcats ... Has over 25 unique definitions spread over 1k+ makefiles. The c code will be compiled differently from directory to directory. My current thought is to do something like define cflags1 $(1) : $(2) $(CC) -Ddogs -Dcats ... endef Now what Paul suggested I look at was the pattern rules. %.o : %.c Bu these are wild card patterns for all .c. This I cannot have. Is it possible to associate a patter rule with a particular list LIST_1 := a.c b.c d.c ... $(LIST_1) : $(LIB)(%.o) : %.c $(CC) -Ddogs -Dcats ... Or is it $(LIB)(%.o) : $(LIST_1) ... Main point, I cannot associate all .c files to one pattern rule. I have some 400 + directories that may contain c/cpp/cobol If I can associate a single pattern rule with a particular list that would be great. Unless I can do it I'll be generating $(LIB)(dogs.o) : dogs.c blablabla $(LIB)(cats.o) : cats.c blablabla _______________________________________________ Help-make mailing list [email protected] http://lists.gnu.org/mailman/listinfo/help-make
