From: Paul Smith Date: Thu, 28 Mar 2024 23:08:20 +0000 (-0400) Subject: * doc/make.texi (Pattern Rules): Clarify that rules must have recipes. X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=033330e34c25b507359299272e567065182addad;p=thirdparty%2Fmake.git * doc/make.texi (Pattern Rules): Clarify that rules must have recipes. --- diff --git a/doc/make.texi b/doc/make.texi index ae016090..cb7420d0 100644 --- a/doc/make.texi +++ b/doc/make.texi @@ -10716,8 +10716,13 @@ pattern for matching file names; the @samp{%} can match any nonempty substring, while other characters match only themselves. The prerequisites likewise use @samp{%} to show how their names relate to the target name. -Thus, a pattern rule @samp{%.o : %.c} says how to make any file -@file{@var{stem}.o} from another file @file{@var{stem}.c}. +Thus, a pattern rule @samp{%.o : %.c ; @var{recipe}} describes a process for +building any file @file{@var{stem}.o} from another file @file{@var{stem}.c} +using the recipe @var{recipe}. + +It is not possible to create a pattern rule that does not have a recipe; +omitting the recipe removes that pattern rule instead (@pxref{Canceling Rules, +,Canceling Implicit Rules}). Note that expansion using @samp{%} in pattern rules occurs @strong{after} any variable or function expansions, which take place