ELF Linker Survey #3 – The Section Header

Piece by piece we’re hunting it down here. As we know from Survey #1, the ELF Header contains an offset to the section header table. The “table” is just an array of section header’s. What are they used for? As the sections may be spread throughout the file, we need some kind of information where each section starts, ends, what type of section it is, and so on.

So ELF provides us with section headers. Their format looks like this:

elf32sectionheader

Read the rest of this entry »

ELF Linker Survey #2 – The Program Header

Ok, we’ve covered the general file format and the ELF header in the previous section. So now we’ll take care of the program header. There’s not much in there, just take a look:elf32programheader

Read the rest of this entry »

ELF Linker Survey #1 – The Header Format

The MOSA compiler is already able to produce valid PE binaries. But as PE isn’t the only binary format that’s out there, we’re alo working on an ELF Linker.

In this series of articles I’ll describe the format, occured problems, etc that I had to tackle during development. So let’s get this thing started with the format itself and especially it’s header. In picture 1 below, you can see a rough sketch for the ELF file format. Each ELF file contains a header, program header, a section header table, section headers, sections, and so on.

Read the rest of this entry »

Follow

Get every new post delivered to your Inbox.