.a .so .bin 文件格式分析--文件格式是32位还是64位,数据是大端还是小端,运行在 arm 上还是 x86上

可通过readelf指令,分析文.a .so .bin 文件是在什么系统上编译的,文件格式是32位还是64位,数据是大端还是小端,运行在 arm 上还是 x86上

1:格式读取说明

通过 readelf -a libbrd.a 读取文件的格式内容

File: libbrd.a(brd_audio.o)
ELF Header:
  Magic:   7f 45 4c 46 01 01 01 00 00 00 00 00 00 00 00 00 
  Class:                             ELF32
  Data:                              2's complement, little endian
  Version:                           1 (current)
  OS/ABI:                            UNIX - System V
  ABI Version:                       0
  Type:                              REL (Relocatable file)
  Machine:                           ARM
  Version:                           0x1
  Entry point address:               0x0
  Start of program headers:          0 (bytes into file)
  Start of section headers:          10924 (bytes into file)
  Flags:                             0x5000000, Version5 EABI
  Size of this header:               52 (bytes)
  Size of program headers:           0 (bytes)
  Number of program headers:         0
  Size of section headers:           40 (bytes)
  Number of section headers:         22
  Section header string table index: 21

2:关键内容说明

2.1 Class

ELF32:说明该文件格式是32位系统格式

2.2 Data

2’s complement, little endian:说明数据格式位为小端

2.3 Machine

ARM:说明当前文件运行在 arm架构 的系统上

最近更新

  1. docker php8.1+nginx base 镜像 dockerfile 配置

    2024-03-10 11:12:05       94 阅读
  2. Could not load dynamic library ‘cudart64_100.dll‘

    2024-03-10 11:12:05       101 阅读
  3. 在Django里面运行非项目文件

    2024-03-10 11:12:05       82 阅读
  4. Python语言-面向对象

    2024-03-10 11:12:05       91 阅读

热门阅读

  1. 同比和环比

    2024-03-10 11:12:05       34 阅读
  2. 【DevOps基础篇之k8s】Kubernetes API服务认证/授权

    2024-03-10 11:12:05       42 阅读
  3. ZooKeeper和Diamond有什么不同

    2024-03-10 11:12:05       47 阅读
  4. 学习Android的第二十六天

    2024-03-10 11:12:05       36 阅读
  5. 产品经理简历话术整理

    2024-03-10 11:12:05       50 阅读
  6. 登录失败重试次数安全设计方案

    2024-03-10 11:12:05       39 阅读
  7. 【设计模式】外观模式

    2024-03-10 11:12:05       43 阅读