<div dir="ltr">> kernels aren't numbered in a suitable way. On Debian for example, packages like linux-image-amd64 are versioned with the full kernel version - eg: 6.12.73-1, or 7.0.4-1~bpo13+1.<br><br>I really don't understand this argument. What's stopping you from simply incrementing the minor? After all, if ZFS only supports up to 6.19, and you specify <6.20, then it doesn't matter if 6.20 exists, it's still less than 7.0. You're literally already using it in `Recommends` ("linux-libc-dev (<< 6.20~)"), I don't understand why you couldn't also use it in `Depends`.<br><br>> I maintain a local package "zfs-linux-image-amd64" which strictly depends on specific kernel and zfs-dkms | zfs-modules versions<br><br>I don't like this. I specifically chose Debian because I don't want to touch my server *at all*. So anyway, I wrote a little hook (`DPkg::Pre-Install-Pkgs`) that does what I want:<br><br>```bash<br>#!/usr/bin/bash<br><br>cat | while read p; do<br>    [[ $p == */zfs-dkms_* ]] || continue<br>    t=/tmp/$(basename $p .deb)<br>    dpkg-deb -R $p $t<br>    sed -i "/^Depends:/{/linux-image-amd64/!s/$/, linux-image-amd64 (<< $(awk '/^Linux-Maximum:/{split($2,v,".");print v[1]"."v[2]+1}' $t/usr/src/*/META)~)/};/^Version:/s/$/+/" $t/DEBIAN/control<br>    dpkg-deb -b $t $p<br>    rm -r $t<br>done<br>```<br><br>(I had to also increase the version otherwise it would reinstall the same version over and over again)</div>