In ancient days the pope was pope by virtue of being bishop of Rome, rather than the other way around. Only the Roman clergy had a voice in electing him. It's an interesting sophistry, typical of Catholics, that this is still true today: every member of the College of Cardinals is a titular bishop, priest or deacon of a church in the diocese of Rome. (That is why they are called Cardinal Deacons, Cardinal Priests or Cardinal Bishops -- it has nothing to do with their normal rank of ordination in the church, nearly all of them being bishops.)
Ancient records of bishops of Rome, recorded by Irenaeus, Julius Africanus, Hippolytus, Eusebius, and the Liberian catalogue of 354 (the others are earlier; 2nd century) list Linus after Peter. There is a dissenting opinion, from Tertullian, who says Clement came after Peter. Irenaeus, whose records are oldest, identifies Linus with the Linus mentioned by Paul in 1 Timothy. He says that Peter and Paul handed the office over to Linus, who was followed by Anacletus. No details are given on how these men were chosen.