Fix custom warning level support.

Fixed custom warning level support so that each non-header target can
have its own warning level set.