add preprocess and postprocess functions when available.  also allow
'source' input for more modules. fixes #5