Generally, the simplest compiler tool chain is the environment of Binutils+GCC+Glibc+kernel-header combination. GCC is a compiler, and its output can only have one architecture instruction output at a time. If you want multiple schema outputs, you must install multiple.
It is impossible for a tool chain to have only GCC. It also needs a binary connector of binutils and a C library of the most basic target architecture. C library also needs a kernel source code of the target architecture to work completely (of course, it is not necessary, but compilation is sometimes necessary).
Because GCC and binutils can't realize the output of single software and multiple architectures at the same time, they need to be installed separately. In addition, the C library and the kernel header file need something of the target architecture, and cannot use the data of the local architecture.
The source code mainly has the following two functions:
1. Generate the target code, which is the code that the computer can recognize.
2. Explain the software, that is, explain the writing of the software. Many beginners, even a few experienced programmers, ignore the compilation of software instructions, because this part will not be directly displayed in the generated program and will not participate in the compilation. However, annotation code is of great benefit to software learning, sharing, maintenance and software reuse.
It should be pointed out that modifying the source code cannot change the generated target code. If the target code needs to be modified accordingly, it must be recompiled.