From 2a80bb9c4edb45c8dc5c6cb7ce4a5bd7521eabef Mon Sep 17 00:00:00 2001 From: iampi31415 <202419735+iampi31415@users.noreply.github.com> Date: Tue, 8 Jul 2025 10:17:06 +0100 Subject: [PATCH] fix: add backticks to variable The word "then" was added because it would be hard to read otherwise, since there are two `...` siblings as in `a.b` `b`. --- content/posts/elf-linkage/index.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content/posts/elf-linkage/index.md b/content/posts/elf-linkage/index.md index 750f8fc..4ebfe59 100644 --- a/content/posts/elf-linkage/index.md +++ b/content/posts/elf-linkage/index.md @@ -112,7 +112,7 @@ Libraries (both static and dynamic) behave similar to object files. They are rea Except for libraries, the linker is lazy. If a library does *not satisfy any currently undefined symbols*, it's *not* read at all. So for example, if instead of `b.o` we had `libb.a` linked in via `-lb`, the library would be linked in, as it can provide the `dependency` symbol. -But if we instead did `ld -lb a.o`, b would be skipped, and then `a.o` would be read, and the `dependency` symbol would be unsatisfied! +But if we instead did `ld -lb a.o`, then `b` would be skipped, and then `a.o` would be read, and the `dependency` symbol would be unsatisfied! To get around this, we always need to ensure that we provide each library and object file before its dependencies, so passing the dependency tree in a preorder/topologically sorted order, if you're into that terminology.