Triss a5fba18d8c | ||
---|---|---|
img | ||
README.md | ||
combining-versions.md | ||
eh_frame.md | ||
eh_frame_hdr.md | ||
elf.html | ||
elf.md | ||
executable-stack.md | ||
gcc-exception-frames.md | ||
gcc_except_table.md | ||
linker-combreloc.md | ||
linker-relro.md | ||
linkers-1.md | ||
linkers-2.md | ||
linkers-3.md | ||
linkers-4.md | ||
linkers-5.md | ||
linkers-6.md | ||
linkers-7.md | ||
linkers-8.md | ||
linkers-9.md | ||
linkers-10.md | ||
linkers-11.md | ||
linkers-12.md | ||
linkers-13.md | ||
linkers-14.md | ||
linkers-15.md | ||
linkers-16.md | ||
linkers-17.md | ||
linkers-18.md | ||
linkers-19.md | ||
linkers-20.md | ||
maskray-1.md | ||
maskray-2.md | ||
maskray-3.md | ||
maskray-4.md | ||
maskray-5.md | ||
maskray-6.md | ||
maskray-7.md | ||
maskray-8.md | ||
masto-thread.md | ||
piece-of-pie.md | ||
protected-symbols.md | ||
version-scripts.md |
README.md
airs-notes
Source
https://www.airs.com/blog/index.php?s=linkers+part
Authored and copyright by Ian Lance Taylor, collected here fore easy lookup.
Index
Main series
- Linkers part 1: introduction
- Linkers part 2: technial introduction
- Linkers part 3: address spaces, object file formats
- Linkers part 4: shared libraries
- Linkers part 5: shared libraries redux, ELF symbols
- Linkers part 6: relocations, position-dependent libraries
- Linkers part 7: thread-local storage
- Linkers part 8: ELF segments and sections
- Linkers part 9: symbol versions, relaxation
- Linkers part 10: parallel linking
- Linkers part 11: archives
- Linkers part 12: symbol resolution
- Linkers part 13: symbol versions redux
- Linkers part 14: link-time optimization, initialization code
- Linkers part 15: COMDAT sections
- Linkers part 16: C++ template instantiation, exception frames
- Linkers part 17: warning symbols
- Linkers part 18: incremental linking
- Linkers part 19:
__start
and__stop
symbols, byte swapping - Linkers part 20: ending note
Other articles included as well
- GCC exception frames
- Linker combreloc
- Linker relro
- Combining versions
- Version scripts
- Protected symbols
.eh_frame
.eh_frame_hdr
.gcc_except_table
- Executable stack
- Piece of PIE
Even more articles, from MaskRay's blog
- Stack unwinding
- All about symbol versioning
- C++ exception handling ABI
- LLD and GNU linker incompatibilities
- Copy relocations, canonical PLT entries and protected visibility
- GNU indirect function
- Everything I know about GNU toolchain
- Metadata sections, COMDAT and
SHF_LINK_ORDER
External links
Here's a collection of links about the subject, I'm putting these here because people seem to find these useful.
elf(5)
manpage- unofficial ELF docs (has more than the manpage, also has extra links)
- glibc internals
- stuff about
.gnu.hash
- Linux Internals & Dynamic Linking Wizardy; Linux Internals: The Art of Symbol Resolution
- LWN article on the vDSO, the vDSO is a dynamic library automatically inserted into every process by the kernel, containing fast implementations of a few syscalls
- "The bits between the bits: how we get to
main()
", a talk, mostly talks about process instantiation - Everything You Always Wanted to Know About "Hello, World", another talk
- "How programs get run" (LWN), part 1, part 2, also talks about eg. initial stack layout
- Glibc startup procedure, technically hurd but mostly the same on Linux
- The difference between all the
crt*.o
files - Official x86-64 ELF ABI spec (PDF)
- Official ELF Auxiliary vector reference
- Glibc ld.so source code
- GNU ld source code
- Glibc How to debug ld.so
- Anatomy of a system call, LWN, part 1, part 2
- "Linkers and Loaders", a book (PDF), more meant for general concepts than nitty ELF details. Also talks about Java for some reason.
- A Whirlwind Tutorial on Creating Really Teensy ELF Executables for Linux
- The Quest for minimal ELF binaries
- Linux sizecoding wiki
- Rough transcriptions of a thread on Mastodon, my posts had some useful info in them, so I saved these in this document.