Augustine, City of God, book 20, chapter 6:
He continues, “Truly, truly, I say to you, the time is coming, and has already come, that the dead will hear the voice of the Son of God, and those who hear him will live; for as the Father has life in himself, he has also given to the Son to have life in himself” (Jn 5:25-26). He is not yet speaking of the second resurrection, i.e. the resurrection of bodies, which is to take place at the end of the world, but of the first, which is taking place now. It is to distinguish this one from the other that he says: “The time is coming, and has already come”. Now, this resurrection does not concern bodies, but souls. Souls also have their death, which consists in impiety and crime; and it is of this [death] that those have died of whom the Lord said: “Let the dead bury their dead” (Mt 8:22), that is, let those who have died of the death of the soul bury those who have died of the death of the body. Of those who have died the death of the soul through impiety and crime, he says: “The time is coming, and has already come, when the dead will hear the voice of the Son of God, and those who hear will live”. Those, he says, who hear him, that is, who obey him, believe in him and persevere to the end. He makes no distinction here between the good and the bad, because it is to everyone’s advantage to hear his voice and live, passing from the death of impiety to the life of grace. It is of this death that Saint Paul says: “Therefore all died, and one died for all, so that those who live might no longer live for themselves, but for him who died and rose again for their sake” (1 Cor 5:14-15). Thus, all without exception died by sin, either original sin or the present sins they have added to it, through ignorance or malice, and only a living one, i.e. free from all sin, died for all these dead, so that those who live because their sins have been forgiven them, no longer live for themselves, but for him who died for all of us for our sins, and rose again for our justification; so that, believing in him who justifies the ungodly, and being justified from our ungodliness as the dead who rise again, we may belong to the first resurrection which is now taking place. Only those who will be eternally happy belong to this one, whereas the Apostle teaches us that both the good and the wicked will belong to the second, which he will speak about shortly. This is why the Psalmist says: “Lord, I will sing of your mercy and your judgment” (Ps 100:1).
It is of this judgment that Saint John speaks next, when he says: “And he gave him power to judge, because he is the Son of man”. By this he shows that he will come to judge, clothed in the same flesh in which he came to be judged. And for this reason he says: “Because he is the Son of man”. Then, speaking of what we are dealing with: “Do not marvel at this,” he says, “for the time will come when all who are in the tombs will hear the voice of the Son of Man; and those who have lived well will come out to resurrect to life, just as the others will resurrect to judgment.” (Jn 5:27-29) This is the judgment of which he spoke earlier, to designate condemnation, in these terms: “He who hears my word and believes in” him who sent me, has eternal life, and will not come into judgment, but “has already passed from death to life” (Jn 5:24). This means that belonging to the first resurrection, by which we now pass from death to life, he will not fall into damnation, which he identifies with judgment, when he says: “Like the others, to resurrect at judgment day”, i.e. to be condemned. So let him who does not wish to be condemned in the second resurrection rise in the first; for: “The time is coming, and has already come, when the dead will hear the voice of the Son of God; and those who hear will live”. In other words, they will not fall into the damnation which Scripture calls the second death, and into which, after the second resurrection, which is that of bodies, those who did not rise in the first resurrection, which is that of souls, will be thrown. He continues: “The time will come”; (and he does not add: “and it has already come”, because that will only come at the end of the world, at the great and final judgment of God). – The time,” he says, “will come when all those in the tombs will hear his voice and come out”. He does not say, as he does when he speaks of the first resurrection, that those who “hear him will live”. Indeed, not all who hear him will live, at least not of the life that alone deserves this name, because it is happy. If they didn’t have some kind of life, they wouldn’t be able to hear him, nor to leave their tombs when their bodies rise again. But then he tells us why not everyone will live: “Those,” he says, “who have lived well will come out to resurrect to life”, these are the ones who will live; “and the others to resurrect at the judgment”, these are the ones who will not live, because they will die of the second death. If they have lived badly, it is because they have not been resurrected in the first resurrection which is now taking place, that is, in the resurrection of souls, or because they have not persevered in it to the end. Just as there are two generations, of which I have already spoken above, one according to faith, which takes place now through baptism, and the other according to the flesh, which will take place at the last judgment, when the flesh will become immortal and incorruptible, so there are two resurrections. The first, which is that of souls, is taking place now; it prevents us from falling into the second death. The other will only take place at the end of the world; it does not concern souls, but bodies, which it will send, as a result of the last judgment, some into the second death, and others into the life where there is no death.