..., but also *manually* (avoiding automatic setup for gmail!) adding imap account for gmail, typing ports by the hand etc, should help. I haven't tried it yet, it's just a theory.