build: Use AM_CFLAGS for warning flags instead of AM_CPPFLAGS

... because those are meant for the compiler, not the preprocessor.