The current recursion depth of 512 is rather large and causes out-of-memory errors on even fairly beefy machines.
This patch reduces the recursion limit to 64, which allows plasma-desktop to be compiled on a test of a simulated very low-end machine in a VM: 2 processors with 2 GB RAM and no virtual memory.
BUG: 362946
FIXED-IN: 5.12.8