(Please cc: me as I'm not subscribed to the list)

This may be a little frivolous, but in GNU Octave's top-level
Makefile.am, we override the check: target:

    http://hg.savannah.gnu.org/hgweb/octave/file/1bfca2bbea8b/Makefile.am#l106

However, in the generated Makefile, this produces a warning:

    Makefile:2354: warning: overriding commands for target `check'
    Makefile:1948: warning: ignoring old commands for target `check'

because the generated Makefile contains these lines:

    ## Standard target
    check: $(BUILT_SOURCES)
       $(MAKE) $(AM_MAKEFLAGS) check-recursive

    ## Overriden target
    check: all
       $(MAKE) -C test check

I would like to silence that warning. It clutters my compilation
buffer when I'm in Emacs and want to quickly jump to the first error
or warning with C-x `. It would suffice if I could make the check:
target empty. Can you please explain under what conditions the check:
target actually has a script involved? I tried making a minimal
example of my own with Automake, and it produced something like this:

    ...
    check: check-recursive
    all-am: Makefile config.h
    ...

i.e. an empty target. So I can override check: without getting a
warning. When does this happen? When is the check: target empty and
when does it actually have a command in there?

TIA,
- Jordi G. H.

Reply via email to