That are not arcane ways, it is the ONLY way just like in any other programming language. You should simply recompile the rtl/fcl/lcl with debug info enabled.
Nice script you got there, but what is it supposed to do? It doesn't seem to take any parameters, so while showing how to use "make" to rebuild fpc it does not help turning on or off debugging.There is always space for improvement. You can see that -j %THREADS% FPMAKEOPT="-T %THREADS%" was used as a parameter on several places. You can make it a new environment variable and make parameters also configurable. Then deciding whether you want debugging or not would be a piece of cake.
Think it does also contain a little glitchNice catch. Feel free to fix it. If you don't, then I will when I find some time.