Gimp (2.10) does it already. No extra software or plugins needed.
That's all! Enjoy.
15.4k 11 11 gold badges 54 54 silver badges 91 91 bronze badges answered Dec 5, 2018 at 10:43 651 5 5 silver badges 2 2 bronze badgesNot only does GIMP do this built in, but it's even clever enough that if you want to have multiple layers make up a page e.g. a base image and various additional text layers - you can do this using layer groups and then with the 'Layers as pages' option, GIMP will export each layer group as a separate page!
Commented Nov 6, 2019 at 1:53 The installed GIMP I have on Ubuntu 16.04 (GIMP 2.8.16) does not have this option. Commented Nov 21, 2019 at 0:04 GIMP 2.8.18 does not have this option Commented Nov 24, 2019 at 9:41 No it doesn.t. Even after clicking on export, there is no such am option Commented Mar 21, 2021 at 9:46Sorry using Gimp 2.8.22 still has not the "export layers as pages" option. In fact, I did not start importing a pdf but had separate images from photographing a multipage document with a smartphone. So I opened those separately and pasted all together into one stack of layers. The export as mng and the convert did the job for me (see next answer).