add undef handling in the preprocessor