Hello,

I was wondering if there is any method to suppress the following type
of messages:

Makefile:98: warning: overriding commands for target `lib'
Makefile:50: warning: ignoring old commands for target `lib'
Makefile:98: warning: overriding commands for target `cli'
Makefile:60: warning: ignoring old commands for target `cli'
Makefile:98: warning: overriding commands for target `debug'
Makefile:54: warning: ignoring old commands for target `debug'
Makefile:98: warning: overriding commands for target `cli-debug'
Makefile:66: warning: ignoring old commands for target `cli-debug'
[...]

The reason they come up is because we do a little (possibly kludgy,
but it works well for our needs) "magic" with a make variable CFG that
defines certain build parameters, and if it's not defined, build all
possible configurations.

The code that generates most of this looks like this:

# This will override the targets for make's without a CFG=
# Will generate warnings for override and ignore, may be ignored.
# Update this when adding new targets
ifndef CFG
lib cli debug cli-debug dll dll-debug distro main cli-distro dll-distro:
        $(foreach cfg,$(cfg_list), $(MAKE) CFG=$(cfg) $@;)
endif

While this may very well not be a best practice method to do this, is
there any way to ignore and suppress these warnings? Because we are
recalling ourselves recursively, they are displaying many times over.

Thank You,
Vincent Castellano


_______________________________________________
Help-make mailing list
Help-make@gnu.org
http://lists.gnu.org/mailman/listinfo/help-make

Reply via email to