bug-make
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [bug #60165] Multiple pattern rules with single rule


From: Paul Smith
Subject: Re: [bug #60165] Multiple pattern rules with single rule
Date: Tue, 19 Jul 2022 14:52:40 -0400
User-agent: Evolution 3.44.3 (by Flathub.org)

On Tue, 2022-07-19 at 20:26 +0200, Jean-Baptiste Poittevin wrote:
> a% b%: %
>         cp $< $@

This rule is not well-formed.  By declaring two patterns as targets,
you are telling make that your recipe will build both targets after
successfully being invoked one time.

If your recipe doesn't actually do that, there's not much make can do
about it, and you'll get unexpected behavior such as what you saw.

See
https://www.gnu.org/software/make/manual/html_node/Pattern-Intro.html
at the bottom, which references
https://www.gnu.org/software/make/manual/html_node/Multiple-Targets.html



reply via email to

[Prev in Thread] Current Thread [Next in Thread]