Score:0

How do I override a missing dependency?

cn flag
sds

I installed a package using dpkg --force-depends -i because it requires libidn11 which is no longer provided.

I then created a symlink from libidn.so.11 to libidn.so.12 (auto-installed) and the package now works just fine.

However, I no longer can update the system using apt full-upgrade because I get

You might want to run 'apt --fix-broken install' to correct these.
The following packages have unmet dependencies:
 icaclient : Depends: libidn11 but it is not installable
...
E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).

Alas, apt --fix-broken install just removes icaclient which is not an option.

So, is there a way to tell apt to ignore all problems with a specific package and pretend that all its dependencies are met?

Score:0
cn flag
sds

I feel like a cheat, but here is what I did and apt upgrade no longer complains:

  1. Open icaclient.deb in Emacs. Get an archive buffer:
M    Mode       Size       Date&time       Filename
- ----------  --------  ----------------  ----------------
  -rw-r--r--         4  2020-04-16 08:18  debian-binary
  -rw-r--r--     53421  1969-12-31 19:00  control.tar.gz
  -rw-r--r--  72952536  2020-04-16 08:20  data.tar.xz
- ----------  --------  ----------------  ----------------
              73005961                     3 files
  1. Open control.tar.gz (hit Enter on it), get a tar buffer:
 drwxr-xr-x    root/root          0 ./
 -rw-r--r--    root/root      54528 ./md5sums
 -rw-r--r--    root/root        921 ./control
 -rwxr-xr-x    root/root        160 ./postrm
 -rwxr-xr-x    root/root        918 ./preinst
 -rw-r--r--    root/root        879 ./conffiles
 -rwxr-xr-x    root/root      70411 ./prerm
 -rwxr-xr-x    root/root      70579 ./postinst
  1. Open control (again, hit Enter on it), edit the text file, replacing libidn11 with libidn12.

  2. Save control (hit C-x C-s).

  3. Save control.tar.gz (switch to it and hit C-x C-s).

  4. As root, apt --fix-broken install and accept removal of icaclient.

  5. As root, dpkg -i icaclient.deb - no warnings, not errors!

  6. As root, cd /usr/lib/x86_64-linux-gnu; ln -s libidn.so.12 libidn.so.11.

I am sure there is a way to do it without Emacs, but I am also quite sure it will be way more keystrokes.

I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.