This fixes handling of -fsanitize=foo flags, as well as supporting flags
like -fsanitize-foo-bar. Since gcc seems to be using that namespace for
all these settings, allow them all.
setup-allowed-flags() {
ALLOWED_FLAGS="-pipe"
ALLOWED_FLAGS+=" -O -O1 -O2 -Os -Og -mcpu -march -mtune"
- ALLOWED_FLAGS+=" -fstack-protector* -fsanitize=*"
+ ALLOWED_FLAGS+=" -fstack-protector* -fsanitize*"
ALLOWED_FLAGS+=" -fbounds-check -fbounds-checking -fno-strict-overflow"
ALLOWED_FLAGS+=" -fno-PIE -fno-pie -nopie -fno-unit-at-a-time"
ALLOWED_FLAGS+=" -g -g[0-9] -ggdb -ggdb[0-9] -gdwarf-* gstabs -gstabs+"