Shared Libraries in Windows and Linux
summary
Compares Windows IAT import/export model (import libs produce import stubs and export stubs) to Linux PLT/GOT lazy binding where the loader (ld‑linux.so) fills GOT slots on first call; shows that Linux requires -fPIC for shared libs, defaults to lazy binding (LD_BIND_NOW overrides), and allows executable interposition and circular shared‑lib deps while Windows forbids them and supports optional delay‑load. Notes mismatch with C++ standard on replacing memory allocators and function pointer equality.
AI-written summary · about
chapters (22)
- 0:00Intro
- 1:47Intro to Linking in 3 slides, #1
- 5:54Import data section
- 6:18idata section layout
- 7:35Import Library
- 9:51Windows Schematic Interface
- 10:27Linux import sections
- 10:49Linux Schematic Interface
- 19:21Resolution Time
- 20:24Linux: Intermediate Summary
- 21:05How to form a process-wide singleton?
- 21:51Can you have circular library dependencies?
- 24:44Can a shared-library symbol be overridden from an executable?
- 29:16Procedure Linkage Table (PLT)
- 32:18Comparing Func Ptrs
- 34:48Windows .idata section
- 35:19No analogue mechanism in Windows
- 36:13Symbol Visibility - Windows
- 37:18Symbol Visibility - Linux
- 40:44Component Map
- 42:38C++ and Shared Libs
- 48:26Resources
related talks
01h 04mThe Bits Between the Bits: How We Get to main()
32mOpen Source C/C++ Embedded Toolchains Using LLVM
12mLibc++ on Linux - using the example of Oniro
04mLink compatibility
01h 02m“Everything You Ever Wanted to Know about DLLs”
46mGNU C Library
01h 00mThe Power and Pain of Hidden Symbols in C++ Programming
31mAmong ELFs and DWARFs
