gcc - How to get the complete path of source C file from its corresponsing binary object file using shell script -


i have object file uart.o trying complete path of source file binary file. using gcc renesas , cosmic compilers. using command - strings -a -f uart.o | grep "uart.c" lines containing paths string command. random data along lines. can complete path of source file object file in other way shell?

an object file not typically encode full path corresponding source file. doing have security implications, since expose details of local filesystem layout access binary.

the compiler operating exclusively on relative paths, anyway, , doesn't know or care complete filesystem path.


Comments

Popular posts from this blog

python - pip install -U PySide error -

arrays - C++ error: a brace-enclosed initializer is not allowed here before ‘{’ token -

cytoscape.js - How to add nodes to Dagre layout with Cytoscape -