PDFtk RPMs for Recent Fedora and CentOS

PDFtk is a useful program for manipulating PDFs. The command line version had generally been packaged with Linux, but not so much now. The program depends on GCJ, the GNU Java compiler, which is is no longer supported.

I miss the thing, so I managed to create some RPMs that install on newer releases. You need to install both the pdftk and gcc6-libgcj RPMs.

Built on Fedora 30 and also tested on 32:
pdftk-2.02-2.fc30.x86_64.rpm
gcc6-libgcj-6.5.0-2.fc30.x86_64.rpm

Built on CentOS 7, and also tested on 8.
pdftk-2.02-2.el7.x86_64.rpm
gcc6-libgcj-6.5.0-2.el7.x86_64.rpm

The method for building these on the systems which don't have GCJ is is nothing nothing clever; just Build GCC 6.5.0 to get the compiler to build pdftk and get the libraries to run it. Those are packaged in the above RPMs, which is all you need.

If you really, really want the old compiler for some reason, you can get that below. Hint: you don't want it.
gcc6-6.5.0-2.fc30.x86_64.rpm
gcc6-6.5.0-2.el7.x86_64.rpm
The compiler RPM contains GCC 6.5.0, the C, C++ and java compilers. These install separately from the standard compiler for your distro, and the RPM does not add them to your executable or library paths. To use the compilers, the RPM provides a small program called gcc6mode, which just sets some environment variables and runs bash. From this, you can run the version 6 compilers. I have tried it out only a little, but it will build pdftk from source, if you're so inclined.

Also, the source RPM. It takes a long time to build since it must first compile the compiler to build the tool. It will produce all three binary RPMs.
pdftk-2.02-2.fc30.src.rpm

It seems to work, but has few other virtues. I have tested the install on my own systems and on some VMs with clean distro installs and it seems to function. Happy hacking.