当前位置: 首页 > news >正文

嵌入式科普(5)ARM GNU Toolchain相关概念和逻辑

一、目的/概述
二、资料来源
三、逻辑和包含关系
四、Arm GNU Toolchain最常用的命令

嵌入式科普(5)ARM GNU Toolchain相关概念和逻辑

一、目的/概述

对比高集成度的IDE(MDK、IAR等),Linux开发需要自己写Makefile等多种脚本。eclipse、Visual Studio等需要了解预处理、编译、汇编、链接的过程,但无需自己完整编写。并且各大芯片厂家都有基于eclipse的IDE(cube ide、e2studio、ccs、MCUX、Simplicity),支持vs code的插件,国产rtt也有基于eclipse的RT-Thread Studio。
所以,我们介绍eclipse+Arm GNU Toolchain+newlib相关概念,使之有个宏观的概念认识。

二、资料来源

Arm GNU Toolchain:
https://developer.arm.com/Tools and Software/GNU Toolchain

Arm Compiler for Embedded(AC6):
https://developer.arm.com/Tools and Software/Arm Compiler for Embedded

IAR Embedded Workbench for Arm:
https://www.iar.com/cn/product/architectures/arm/iar-embedded-workbench-for-arm/

arm gcc编译选项:
https://blog.csdn.net/chshch83/article/details/131932972

三、逻辑和包含关系

图片

  • Arm GNU Toolchain命名规则:
    arm-none-eabi-gcc
    arm:架构是arm
    none:不是特定的供应商提供的
    eabi:eabi:嵌入式应用二进制接口(Embedded Application Binary Interface)
    因为名称里没有“linux”类似的字样,说明不支持操作系统。

四、Arm GNU Toolchain最常用的命令

  • arm-none-eabi-gcc

  • arm-none-eabi-gdb

  • arm-none-eabi-size

  • arm-none-eabi-objdump

arm-none-eabi-gcc "../Core/Src/system_stm32h7xx.c" -mcpu=cortex-m7 -std=gnu11 -g3 -DDEBUG -DUSE_HAL_DRIVER -DSTM32H723xx -c -I../Core/Inc -IC:/Users/jerry/STM32Cube/Repository/STM32Cube_FW_H7_V1.11.1/Drivers/STM32H7xx_HAL_Driver/Inc -IC:/Users/jerry/STM32Cube/Repository/STM32Cube_FW_H7_V1.11.1/Drivers/STM32H7xx_HAL_Driver/Inc/Legacy -IC:/Users/jerry/STM32Cube/Repository/STM32Cube_FW_H7_V1.11.1/Drivers/CMSIS/Device/ST/STM32H7xx/Include -IC:/Users/jerry/STM32Cube/Repository/STM32Cube_FW_H7_V1.11.1/Drivers/CMSIS/Include -IC:/Users/jerry/STM32Cube/Repository/STM32Cube_FW_H7_V1.11.1/Middlewares/Third_Party/FreeRTOS/Source/include -IC:/Users/jerry/STM32Cube/Repository/STM32Cube_FW_H7_V1.11.1/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS_V2 -IC:/Users/jerry/STM32Cube/Repository/STM32Cube_FW_H7_V1.11.1/Middlewares/Third_Party/FreeRTOS/Source/portable/GCC/ARM_CM4F -O0 -ffunction-sections -fdata-sections -Wall -fstack-usage -fcyclomatic-complexity -MMD -MP -MF"Core/Src/system_stm32h7xx.d" -MT"Core/Src/system_stm32h7xx.o" --specs=nano.specs -mfpu=fpv5-d16 -mfloat-abi=hard -mthumb -o "Core/Src/system_stm32h7xx.o"
arm-none-eabi-gcc -o "h723.elf" @"objects.list"   -mcpu=cortex-m7 -T"E:\st_workspace\h723\STM32H723VETX_FLASH.ld" --specs=nosys.specs -Wl,-Map="h723.map" -Wl,--gc-sections -static --specs=nano.specs -mfpu=fpv5-d16 -mfloat-abi=hard -mthumb -Wl,--start-group -lc -lm -Wl,--end-group
Finished building target: h723.elfarm-none-eabi-size   h723.elf 
arm-none-eabi-objdump -h -S  h723.elf  > "h723.list"
  • arm-none-eabi-objcopy

arm-none-eabi-objcopy -O ihex "rzn2l_coremark.elf"  "rzn2l_coremark.hex"
arm-none-eabi-size --format=berkeley "rzn2l_coremark.elf"
  • --specs=nano.specs

  • --specs=nosys.specs

  • -u _printf_float

  • .ld链接脚本
    GNU LD脚本命令语言:
    https://blog.csdn.net/tianizimark/article/details/125865933

  • Makefile相关自动生成

图片

http://www.lryc.cn/news/264938.html

相关文章:

  • Elasticsearch:什么是文本分类?
  • 指针(3)
  • 外汇天眼:我碰到外汇投资骗局了吗?学会这5招,轻松识别外汇诈骗黑平台!
  • 一文解析子网掩码和默认网关,成为网络设置达人
  • 二分查找法详解(6种变形)
  • uniapp uview 页面多个select组件回显处理,默认选中
  • linux中playbook的控制语句
  • MongoDB介绍
  • 再看参数校验
  • 计算机存储术语: 扇区,磁盘块,页
  • 解决IDEA编译/启动报错:Abnormal build process termination
  • Jetpack DataStore
  • 在Portainer创建Nginx容器并部署Web静态站点实现公网访问
  • 泛微e-cology XmlRpcServlet文件读取漏洞复现
  • 当下流行的直播技术demo演示
  • Zabbix自动发现并注册已安装agent的主机
  • Jtti:linux搭建开源ldap服务器的方法
  • Gazebo GUI模型编辑器
  • pycharm运行正常,但命令行执行提示module不存在的多种解决方式
  • GBASE南大通用GBase 8a ODBC的安装文件
  • 重新配置torch1.8 cuda11.1 torchtext0.9.0虚拟Pytorch开发环境
  • 【动画图解】一次理清九大排序算法!面试官问到再也不慌!
  • 组播地址段及其作用
  • Vue+ElementUI前端添加展开收起搜索框按钮
  • 速盾网络:sdk游戏盾有什么作用?
  • 理解BeEF的架构
  • esp32-s3训练自己的数据进行目标检测、图像分类
  • 华为设备VRP基础
  • 论文笔记 | ICLR 2023 WikiWhy:回答和解释因果问题
  • LC24. 两两交换链表中的节点