Opensource WPP analog?

Does anybody know a tool similar to WPP, with source available? Basically, a preprocessor which converts printf-style statements to calls to other functions, not printf-like and not variadic?

/* I apologize if it sounds like I’m doing a non-Windows project - but that’s the truth. */

– pa