博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
ELF文件格式
阅读量:4108 次
发布时间:2019-05-25

本文共 1788 字,大约阅读时间需要 5 分钟。

ELF文件格式

在Blackfin的Linux世界中,有两种基本的文件格式:

  • FLAT:二进制的Flat文件通常被称为BFLT,它是基于原始的a.out格式的一种相对简单的轻量级可执行格式。BFLT文件是嵌入式Linux的默认文件格式。
  • FDPIC ELF:可执行和可链接格式最初是由Unix System实验室开发出来的,现在已经成为文件格式的标准。相对于BFLT格式而言,ELF标准更强大并且更灵活。但是,它更重量级一些,需要更多的磁盘空间以及有一定的运行时开销。

这两种格式都支持静态和动态链接(共享库),但是,ELF更容易使用及创建动态链接库。只有ELF支持动态加载(dlopen(), dlsym(), dlclose()),以及创建和维护共享库的标准方法。

记住在Linux系统下面,我们使用FDPIC ELF格式。FDPIC格式和ELF格式的不同之处,仅仅在于其内部要求在没有MMU的情况下工作。从程序员的角度来说,无论从哪点来看,ELF就是ELF。

-----------------------------------------------------------------------------------------------------------------

Executable file formats:

Files can be in two basic formats in the Blackfin Linux world:

FLAT
Binary
Flat files commonly known as BFLT, are a relatively simple and lightweight executable format based on the original a.out format. BFLT files are the default file format in embedded Linux.
FDPIC ELF
The executable and linking format (
ELF) was originally developed by Unix System Laboratories and has become the standard in file formats. The
ELF standard has greater power and more flexibility than the BFLT format. However, they are more heavyweight, requiring more disk space and having a small run-time penalty.

Both formats support static and dynamic linking (shared libraries), although it is much easier to use and create shared libraries withELF. OnlyELF supports dynamic loading (dlopen(),dlsym(), dlclose()), and the standard method for creating and maintaining shared libraries. (For more information on libraries, see the page.)

Keep in mind that under Linux, we use the FDPIC ELF format. The difference between the FDPICELF format and theELF format is merely in the internals (how the PLT is implemented) as a requirement for working without an MMU. For all intents and purposes from the programmer's perspective, the ELF is anELF.

转载地址:http://qxtsi.baihongyu.com/

你可能感兴趣的文章
TCP三次握手和四次挥手
查看>>
UDP反射放大攻击
查看>>
一次奇葩支付网关漏洞
查看>>
Lucene 8 简单的介绍
查看>>
IoC和DI 简单的介绍和区别
查看>>
Mysql 事务和锁的区别
查看>>
Nodejs实现简易HTTP服务器
查看>>
MDL 内存映射实现HOOK
查看>>
JAVA 和C++ 几个明显区别
查看>>
SpringBoot2.x RestClient 操作ElasticSearch 7.x
查看>>
SOCK_RAW 写一个简单的网络嗅探器
查看>>
Redis 分布式锁和分布式信号量(Python实现)
查看>>
AMQP RabbitMQ 打回消息后延迟处理
查看>>
Springboot RedisTemplate 分布式锁
查看>>
Springboot2.x AOP 实现 @Cacheable自定义TTL和自动刷新 防止缓存雪崩
查看>>
CuratorFramework Zookeeper 分布式锁的使用及手动实现
查看>>
记一次帮朋友调试私服服务端的过程
查看>>
Eureka 配置主要参数及含义
查看>>
Zookeeper 安全的修改数据
查看>>
预防缓存穿透方案 - 布隆过滤器/布谷鸟过滤器
查看>>