I’m curious about how Clang (as well as other compilers) handles internal and external libraries.
Basically, I assume that by applying a multi-compilation method, the compiler reads source code files, treats undeclared parts in the file as ‘unresolved symbols’, and based on this rationale, fetches the necessary libraries as whole files. These files are then added to the source code files, parsed, and compiled, to be later combined by the linker. Of course, in C++, the presence of headers can simplify this process.
I’ve been trying to verify this understanding by reading documentation, but I haven’t found any information on this topic.
I want to understand the structure and process of Clang and enhance my understanding of the LLVM frontend. Do you have any recommended resources?