Music while routing a call in IVR aplication

Making a call to any extension in IVR menu I don`t know to set music or ringback while call is routing. I make a call from a Perl AGI scritp:
Anyone can help me?

the m flag says play music on hold until the call is established instead of ringing