Re: patsubst: Whitespaces are not replaced by spaces | Possible issue in make or the documentation
Paul Smith <[email protected]> Wed, 30 Apr 2025 13:29:03 -0400
| Newsgroups | gmane.comp.gnu.make.general |
|---|---|
| Organization | GNU's Not UNIX! |
| Message-ID | <[email protected]> |
Hi Marek! Please choose just onee mailing list to ask your question, rather than sending it to multiple lists. Either one would be appropriate for this question IMO. On Wed, 2025-04-30 at 12:15 +0000, Marek Küthe wrote: > I am currently taking a closer look at the `patsubst` function in > `make`. The documentation [1] says > > Whitespace between words is folded into single space characters; > > leading and trailing whitespace is discarded. I believe that was trying to discuss whitespace etc. within the pattern words, not within the to-be-substituted text. But, it doesn't even work there. I think you should ignore that paragraph in the documentation and pretend it's not there. I have no idea what it really refers to. If you do want to strip out whitespace etc., you should use the $(strip ...) GNU Make function.