|
|
Subscribe / Log in / New account

DNF5 delayed

DNF5 delayed

Posted Aug 23, 2023 5:46 UTC (Wed) by mb (subscriber, #50428)
In reply to: DNF5 delayed by cozzyd
Parent article: DNF5 delayed

I do not want to talk about whether Rust supports dynamic linking (it does), but why do you think dynamic linking is especially needed for a package manager?

I think the opposite is true. Static linking makes a package manager more robust during updates of dependencies that it uses by itself. It's one of the few applications where static linking actually makes much sense.
Ensuring an atomic update of the package manager and all of its dynamic dependencies seems like almost impossible in practice to me.


to post comments

DNF5 delayed

Posted Aug 23, 2023 7:12 UTC (Wed) by cozzyd (guest, #110972) [Link] (1 responses)

Fedora packaging policy is such that dynamic linking is required (see e.g. https://lore.kernel.org/lkml/CAHk-=whs8QZf3YnifdLv57+FhBi... for a famous case). Dynamic linking is possible in rust, but without a stable ABI it's as far as I understand not really recommended or all that useful, except when exporting a C ABI. The same is kind of true for C++ except that the C++ ABI (at least with stdlibc++) is in practice fairly stable with a few notable exceptions.

I'm not sure there is an issue with a package manager updating itself unless it does something silly like reload shared libraries at run time. The replaced library is still going to be the one in its address space? I guess if you did something silly like updated libdnf without updating dnf that could in principle cause problems if the two become incompatible but that shouldn't be possible to do with dnf...

DNF5 delayed

Posted Aug 23, 2023 16:36 UTC (Wed) by mb (subscriber, #50428) [Link]

>The replaced library is still going to be the one in its address space?

Unless the system crashes halfway through the update.


Copyright © 2025, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds