Is it possible to trace loading of开发者_高级运维 ELF executable from typing name of program and pressing enter until execution of main function? If yes, then how to do this?
man ld.so
will tell you about LD_DEBUG.
How about strace?
strace myprog myargs...
This will launch your program and print all the system calls as they are made, which I assume is what you meant by "trace." You can just stop looking at the output once you see your own code being executed.
精彩评论