[build] Avoid hardcoded CFLAGS in configure-mingw