MDK 自带的编译器是 ARMCC 或 ARMCLANG（Arm Compiler 6），有时需要使用 GCC 编译器（例如需要使用 GCC 编译的静态库）。当然，用 GCC 不一定非要用 MDK IDE。 先去 ARM 官网下载 GNU 工具链（Arm GNU Toolchain） Arm GNU Toolchain is a community supported pre-built GNU compiler toolchain for Arm based CPUs. Arm GNU Toolchain releases consists of cross toolchains for the following host operating systems: GNU/Linux Available for x86_64 and AArch64 host architectures Available for bare-metal and Linux targets Windows Available for x86 host architecture only (compatible with x86_64) Available for bare-metal and Linux targets macOS Available for x86_64 host architecture only Available for bare-metal targets only [...]