On this page<https://www.gnu.org/software/make/manual/html_node/Text-Functions.html>, the text is incorrect:
Substitution references (see Substitution References<https://www.gnu.org/software/make/manual/html_node/Substitution-Refs.html#Substitution-Refs>) are a simpler way to get the effect of the patsubst function: $(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
_______________________________________________ Bug-make mailing list Bug-make@gnu.org https://lists.gnu.org/mailman/listinfo/bug-make