Do we have any option in gcc to find from where a particular file header is included.
I have the following scenario :
file_1.h :
declare type of type_1
file_2.h :
type_1 var;
I want to check where was file_1.h included in the library that i am creating.
gcc has an option -M:
If you do,
gcc -M filename.c, it’ll list out all headers. Same with g++.