|
From: | John Ulvr (julvr) |
Subject: | Documentation error for makefile substitution references |
Date: | Tue, 13 Aug 2019 15:04:34 +0000 |
On
this page, the text is incorrect: Substitution references (see Substitution
References) are a simpler way to get the effect of the $(var:pattern=replacement)
is equivalent to $(patsubst pattern,replacement,$(var))
In the first example, if pattern/replacement do not contain % characters then this is not true. (the document specifically says that pattern
may contain a %). I have the following: var=A _A ifneq ( "$(var:A=B)","$(patsubst A,B,$(var))" ) $(info mismatch... "$(var:A=B)" / "$(patsubst A,B,$(var))" ) endif With output: mismatch... "B _B" / "B _A" John |
[Prev in Thread] | Current Thread | [Next in Thread] |