git: 537f945fc89f - main - Makefile.libcompat: Quote CFLAGS and CXXFLAGS for sub-make
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sun, 09 Jul 2023 17:51:59 UTC
The branch main has been updated by jrtc27: URL: https://cgit.FreeBSD.org/src/commit/?id=537f945fc89fab53f60fee07ac42c8aeab704ce7 commit 537f945fc89fab53f60fee07ac42c8aeab704ce7 Author: Jessica Clarke <jrtc27@FreeBSD.org> AuthorDate: 2023-07-09 17:46:12 +0000 Commit: Jessica Clarke <jrtc27@FreeBSD.org> CommitDate: 2023-07-09 17:46:12 +0000 Makefile.libcompat: Quote CFLAGS and CXXFLAGS for sub-make Currently none of the words in these require quoting, but a future commit will add words that do, thus we should make sure to quote each word so the shell doesn't mangle them before calling the sub-make. (Note that :@var@expr@ is the bmake syntax for map, replacing each word with expr's evaluation, with var containing the input word) Reviewed by: emaste, brooks, jhb Differential Revision: https://reviews.freebsd.org/D40921 --- Makefile.libcompat | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Makefile.libcompat b/Makefile.libcompat index 4bcb7479270c..72ea4d865647 100644 --- a/Makefile.libcompat +++ b/Makefile.libcompat @@ -25,9 +25,9 @@ LIB${_LIBCOMPAT}WMAKEENV+= \ # Don't rebuild build-tools targets during normal build. LIB${_LIBCOMPAT}WMAKEENV+= BUILD_TOOLS_META=.NOMETA .endif -LIB${_LIBCOMPAT}WMAKEFLAGS+= CC="${XCC} ${LIB${_LIBCOMPAT}CFLAGS}" \ - CXX="${XCXX} ${LIB${_LIBCOMPAT}CXXFLAGS} ${LIB${_LIBCOMPAT}CFLAGS}" \ - CPP="${XCPP} ${LIB${_LIBCOMPAT}CFLAGS}" \ +LIB${_LIBCOMPAT}WMAKEFLAGS+= CC="${XCC} ${LIB${_LIBCOMPAT}CFLAGS:@v@${v:Q}@}" \ + CXX="${XCXX} ${LIB${_LIBCOMPAT}CXXFLAGS:@v@${v:Q}@} ${LIB${_LIBCOMPAT}CFLAGS:@v@${v:Q}@}" \ + CPP="${XCPP} ${LIB${_LIBCOMPAT}CFLAGS:@v@${v:Q}@}" \ DESTDIR=${WORLDTMP} \ -DNO_CPU_CFLAGS \ MK_BOOT=no \