Using two small tools from
qpdf might work as well.
Splitting a PDF document:
pdfseparate in.pdf out%d.pdf, can specify the first and last page using
Merging PDF documents:
pdfunite in1.pdf in2.pdf out.pdf
It would be nice if
pdfseparate supported more format specifiers, not just
%0d would be useful working with large documents.