From: Michel Dänzer Date: Wed, 12 Apr 2023 09:24:13 +0000 (+0200) Subject: ci: Explicitly test for meson feature checks in compiler wrapper X-Git-Tag: upstream/23.3.3~9972 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=1915185648e606cf3c32cff1160305260577a5f0;p=platform%2Fupstream%2Fmesa.git ci: Explicitly test for meson feature checks in compiler wrapper The previous indirect method was more complicated and still error prone. v2: * Use "grep -E" (Eric Engestrom) * Exclude spaces and slashes in the grep pattern, to avoid accidentally matching across unrelated compiler arguments. Part-of: --- diff --git a/.gitlab-ci/build/compiler-wrapper.sh b/.gitlab-ci/build/compiler-wrapper.sh index 12a70fe..f20b518 100755 --- a/.gitlab-ci/build/compiler-wrapper.sh +++ b/.gitlab-ci/build/compiler-wrapper.sh @@ -6,8 +6,8 @@ else CCACHE= fi -if [ "$(ps -p $(ps -p $PPID -o ppid --no-headers) -o comm --no-headers)" != ninja ]; then - # Not invoked by ninja (e.g. for a meson feature check) +if echo "$@" | grep -E 'meson-private/tmp[^ /]*/testfile.c' >/dev/null; then + # Invoked for meson feature check exec $CCACHE $_COMPILER "$@" fi