Before I joined 4Js, at the company I worked for we had some home made shell scripts that parsed the source overnight as part of the daily build/smoke test and generated that sort of information. grep ""^FUNCTION" *.4gl | cut -d " " -f2 | cut -d "(" gives you list of functions and then grep -n "
function-name(" *.4gl tells you where it is called. There was a bit more to it than that but it gets you nearly there.
Now I'd use Studio. Just because you have a lot of homemade preprocessing does not stop you using Studio. Studio is quite configurable and appropriate use of build rules, file types, you can mold Studio to fit round your existing development environment. Then you will see the information you seek in the .4pwdb file once dependencies are created. The content in this file is used for code structure
https://4js.com/online_documentation/fjs-gst-manual-html/#c_gst_ce_code_structure_view.html and the dependency diagram/sequence diagram
https://4js.com/online_documentation/fjs-gst-manual-html/#t_gst_tour_anaylzecode.html. In theory, if you wanted to carry on with your existing development environment, just having Studio installed and configured, and a .4pw for your program, you could run gsmake at the command line using -generate-4pwdb
https://4js.com/online_documentation/fjs-gst-manual-html/#c_gst_projectmgr_gsmake.html to build up .4pwdb
Otherwise make sure you have looked at the various command line options for fglcomp, fglrun. (fglcomp -h, fglrun -h will list the public options). fglrun -p will run your program and tell you what functions were actually called (along with the time spent in them), fglcomp --build-rdd will produce a file that contains info about structure of the program. You maybe able to get the information you seek from that output. Also if you have not looked inside a .42r, have a look using (octal dumps (od) and string dump (string)), it might give you info as to what functions are called within a program.
Hope that helps.
Reuben