Ok, but could you recommend an approach for packing multiple libraries with a single rule, that supports varying sources list and flags? Or is this method not of your taste in general?
----- Original message ----- > On 3/9/11, Dmitry N. Mikushin <[email protected]> wrote: > ... > > %.a: INCLUDES += $($(LIBNAME)_INCLUDES) <--- (1) > > %.a: dirs $$(OBJECTS) > > @echo Packing static library $@ ... $(INCLUDES) > > <---(2) > > @$(AR) $(ARPARAMS) $@ $(OBJECTS) > > > > $(STORE)/%.c.o: %.c > > @echo Creating object file for $< ... > > $(CCOMP) $(CPARAMS) $(DEFINES) $(INCLUDES) -c $< -o $@ > > > > <--- (3) > > > > Here at (1) INCLUDES is expanded with library-specific values, and > > changes are visible at (2), but not applied at (3). It turns all > > variables defined in %.a are recomputed in %.c.o with respect to new > > $@, and all information I need to pass from %.a to %.c.o via variables > > is lost. Is there a workaround to deliver %.a's values to %.c.o? > > Sorry, I personally dislike and do not use variable inheritance, so I > don't have any good ideas on how to force it to continue to take > effect here. > > > Philip Guenther _______________________________________________ Help-make mailing list [email protected] http://lists.gnu.org/mailman/listinfo/help-make
