Kodi upgrade 19.4 to 21

That dependency package seems to be not available on Debian Bookworm :thinking:: Debian -- Details of package kodi-inputstream-rtmp in bookworm

It does not work on Trixie either:

Unsatisfied dependencies:
 kodi-inputstream-rtmp : Depends: kodi-api-inputstream (>= 3.3.0)
                         Depends: kodi-api-inputstream (< 3.4.0)
Error: Unable to correct problems, you have held broken packages.
Error: The following information from --solver 3.0 may provide additional context:
   Unable to satisfy dependencies. Reached two conflicting decisions:
   1. kodi:armhf=2:21.2+dfsg-1 is not selected for install
   2. kodi:armhf=2:21.2+dfsg-1 is selected for install because:
      1. kodi-inputstream-rtmp:armhf=21.1.2+ds-1 is selected for install
      2. kodi-inputstream-rtmp:armhf=21.1.2+ds-1 Depends kodi-api-inputstream (>= 3.3.0)

Ohhh, the Debian kodi package provides kodi-api-inputstream to solve the dependency, and the RPi kodi-inputstream-rtmp package does not depend on kodi-api-inputstream. The problem is that APT selects the kodi package from the RPi repo, but the kodi-inputstream-rtmp package from Debian. Reason is that the RPi kodi package has a higher epoch version to be preferred in any case, while this is not true for other Kodi related packages:

2025-03-22 16:06:06 root@micha:/var/log# apt policy kodi-inputstream-rtmp
kodi-inputstream-rtmp:
  Installed: (none)
  Candidate: 21.1.2+ds-1
  Version table:
     21.1.2+ds-1 500
        500 https://deb.debian.org/debian trixie/main armhf Packages
     20.3.0-4~bookworm 500
        500 https://archive.raspberrypi.com/debian bookworm/main armhf Packages
2025-03-22 16:07:41 root@micha:/var/log# apt policy kodi
kodi:
  Installed: (none)
  Candidate: 3:20.5-4~bookworm
  Version table:
     3:20.5-4~bookworm 500
        500 https://archive.raspberrypi.com/debian bookworm/main armhf Packages
     2:21.2+dfsg-1 500
        500 https://deb.debian.org/debian trixie/main armhf Packages

You just need to pull kodi-inputstream-rtmp from the RPi repo. The following sets the priority for the package from the RPi repo one point higher, to achieve this:

echo -e 'Package: kodi-inputstream-rtmp\nPin: origin archive.raspberrypi.com\nPin-Priority: 501' | sudo tee /etc/apt/preferences.d/kodi-inputstream-rtmp
sudo apt install kodi-inputstream-rtmp