modify mainsource