Follow up to #32970
#32970#r2213730157
Does
cmake -S ...still need to be wrapped inbash -c "..."?
#32970#r2213741192
It is not trivial to replace. Maybe the
evalhack from below can be used:# parses TEST_RUNNER_EXTRA as an array which allows for multiple arguments such as TEST_RUNNER_EXTRA='--exclude "rpc_bind.py --ipv6"' eval "TEST_RUNNER_EXTRA=($TEST_RUNNER_EXTRA)"however, I haven't tried this yet.
#32970#r2213801696
Yeah, the eval hack should work:
$ export T="-DREDUCE_EXPORTS=ON -DCMAKE_CXX_FLAGS='-Wno-psabi -Wno-error=maybe-uninitialized'"; eval "T=($T)"; for i in "${T[@]}"; do echo "_${i}_" ; done _-DREDUCE_EXPORTS=ON_ _-DCMAKE_CXX_FLAGS=-Wno-psabi -Wno-error=maybe-uninitialized_(can be done in a follow-up)
This replaces the bash -c wrapper with an eval-based array parsing to preserve spaces in flag values (e.g., in CMAKE_CXX_FLAGS), allowing ShellCheck to lint the cmake command