Linkers part 4 – Airs – Ian Lance Taylor
We’ve talked a bit about what object files and executables look like, so what do shared libraries look like? I’m going to focus on ELF shared libraries as used in SVR4 (and GNU/Linux, etc.), as they are the most flexible shared library implementation and the one I know best. Windows shared libraries, known as DLLs, are less flexible in that you have to compile code differently depending on whether it will go into a shared library or not. You also have to express symbol visibility in the source code. This is not inherently bad, and indeed ELF has picked up some of these ideas over time, but the ELF format makes more decisions at link time and is thus more powerful. When the program linker creates a shared library, it does not yet know which virtual address that shared library will run at. In fact, in different processes, the same shared library will run at different address, depending on the decisions made by the dynamic linker. This means that shared library code must be position indep
Linkers part 4 – Airs – Ian Lance Taylor Linkers part 4 Shared Libraries We’ve talked a bit about what object files and executables look like, so what do shared libraries look like? I’m going to focus on ELF shared libraries as used in SVR4 (and GNU/Linux, etc.), as they are the most flexible shared library implementation and the one I know best. Windows shared libraries, known as DLLs, are less flexible in that you have to compile code differently depending on whether it will go into a shared library or not. You also have to express symbol visibility in the source code
Explore this link on the map →related reading
- Linkers part 2 – Airs – Ian Lance Taylorairs.com
- Linkers part 3 – Airs – Ian Lance Taylorairs.com
- c++ - What do linkers do? - Stack Overflowstackoverflow.com
- A Whirlwind Tutorial on Creating Really Teensy ELF Executables for Linuxmuppetlabs.com
- The "Basics" | Putting the "You" in CPUcpu.land
- DLL hell - Wikipediaen.wikipedia.org
- Inter-process communication in Linux: Shared storage | Opensource.comopensource.com
- It’s Time for a Modern Synthesis Kernel – Embedded in Academiablog.regehr.org
- OS 202 Class Notescs.nyu.edu
- The little book about OS developmentlittleosbook.github.io
- Lab 1: C Programming and Makefiles - HackMDcs.brown.edu
- Compilers - What Every Programmer Should Know About Compiler Optimizations | Microsoft Learnlearn.microsoft.com