Hello,

On Wed, Jun 21, 2006 at 09:51:31PM +0200, Torsten Mohr wrote:
> some rules in my Makefiles are quite similar, but
> not the same.

well, you can use

PARAMS = $(G) $(OPTS) -o $@ -c $<

$(OBJ_C): $(D_OBJ)/%.o : %.c
        $(CC) $(PARAMS)
...

You could probably use target-specific values of a variable:

COMP = $(COMPILER) $(G) $(OPTS) -o $@ -c $<

$(OBJ_C): COMPILER = $(CC)
$(OBJ_C): $(D_OBJ)/%.o : %.c
        $(COMP)
...

But none of these present any simplification in this case, where the
command is short.

Stepan Kasal


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

Reply via email to