"Gisle Vanem" <gva...@yahoo.no> writes: > "Martin Dorey" <martin.do...@hds.com> wrote: > >>> this also removes the newlines. >>... >>> IMHO make 4.x has a too strict definition of white-space. >> >> http://pubs.opengroup.org/onlinepubs/000095399/basedefs/xbd_chap07.html >> sayeth: >> >> "In the POSIX locale, at a minimum, the <space>, <form-feed>, >> <newline>, <carriage-return>, <tab>, and <vertical-tab> shall be >> included." > > Then the make manual is a bit sloppy in the use of "whitespace".
I'd say that make itself is sloppy wrt whitespace, where sometimes newlines are considered to be whitespace, othertimes not. For example, as you reported, gmake's $(strip ...) function treats newlines as whitespace. But the "word" family of functions do not. define x foo bar endef all: echo $(words $(x)) echo $(words $(strip $(x))) Given a choice, I'd prefer the word functions treat newlines as whitespace. --jtc -- J.T. Conklin _______________________________________________ Bug-make mailing list Bug-make@gnu.org https://lists.gnu.org/mailman/listinfo/bug-make