Is there a way to convert wikis to pages and vice versa?

I need to turn a large number of wikis into pages without fouling up their internal links. Is there a way to do that?