I don’t know all the details of this, but I would say that it will be quite some work to get mPDF working on the newer versions - it probably involves using a newer mPDF version than the one that the SuiteCRM code is ready for.
I would advise (if you don’t want to sponsor me to get my PowerReplacer sponsorware) that you invest in fixing any TCPDF problems that you have, instead.
This might help.
It should be possible to get TCPDF (the current only option for PDF templates rendering) to work fine and produce nice-looking PDFs…