4

Ubuntu 17.10 contains libmicrohttpd12 but I also need libmicrohttpd10 for kodi. Can I have both ?

meFrans
  • 41

1 Answers1

3

It is available in 16.04, and installing the 16.04 version on 17.10 is likely to work (assuming you really cannot install 16.04; otherwise you should do that). However, do not just download a .deb and install it, because if a vulnerability is found in it, you will not automatically get the fix. Instead, you can add the 16.04 repositories as follows.

First, copy your current sources.list to a new file in /etc/sources.list.d:

sudo cp /etc/apt/sources.list /etc/apt/sources.list.d/xenial_for_libmicrohttpd10.list

The name of the new file is just a reminder for the future you of what its purpose is. You can also add a more elaborate comment in it.

Second, use your text editor of choice to replace all occurrences of artful in the file to xenial. For example:

printf ',s/artful/xenial/\nw\n' | sudo ed /etc/apt/sources.list.d/xenial_for_libmicrohttpd10.list

Finally, just to be sure that no Xenial package other than libmicrohttpd10 will be accidentally installed, give them a low priority by creating a file in /etc/apt/preferences.d like this:

Package: *
Pin: release n=xenial
Pin-Priority: 99

Package: libmicrohttpd10
Pin: release n=xenial
Pin-Priority: 500

Then you can do sudo apt update && sudo apt install libmicrohttpd10.

fkraiem
  • 12,813