asciidoctor/asciidoctor-pdf — pull request #43 by DavidGamba (2014-09-08 15:25:46+00:00)
Title: #35 Multipage toc

The first commit https://github.com/DavidGamba/asciidoctor-pdf/commit/71f2711f7f0074e94176ba7ff1ec0f2213b9e7b3 is to make sure you move to the right page before moving the cursor.

The second one https://github.com/DavidGamba/asciidoctor-pdf/commit/1fa846923650fd4b7b9e0edb58ca10b6c6f7cf19 is a way to know how many pages are required for the TOC.

I couldn't find where to create those pages for the TOC to have enough space.

I hope this helps solve the issue.