how to emit machine code to custom MCStreamer


I'd like to emit code to a custom MCStreamer instead of e.g. MCELFStreamer.
Unfortunately LLVMTargetMachine::addCommonCodeGenPasses is private
but I would need it, or even better a method simular to addPassesToEmitFile
(e.g. addPassesToEmitCustomMC) taking an MCSreamer would be great.

What do you think?