This is actually a super-interesting problem. The complex scripts require "shaping", which increasingly is done by HarfBuzz. Companies used to maintain their own proprietary implementations, but that's increasingly not a good idea. A problem is that HarfBuzz is a large, complex piece of software, entirely because OpenType is complex and not well specified (there are a ton of edge cases).
I did some research a few years ago on defining shaping by composing several simple finite state machines together, and am confident it could be made to work. The problem is, it doesn't work with existing fonts, the rules for shaping would have to be redone. But for fonts shipping in an embedded device, this would be entirely practical, and would be a lot faster and a lot less code than a solution based on HarfBuzz.
I'd need some incentive to complete this research. If someone wants to pay for it, please get in touch.