It appears package 'systemd-shim' stopped existing after Ubuntu 16.04, so that's part of the problem. Please try purging it with:
sudo dpkg -P systemd-shim This bug is either 'Fix Released', 'Invalid' or 'Won't Fix'. Because it's not a problem in any package we distribute any more. ** Package changed: xorg (Ubuntu) => systemd-shim (Ubuntu) ** Changed in: systemd-shim (Ubuntu) Status: New => Won't Fix -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1890012 Title: Could not install 'systemd-shim' To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/systemd-shim/+bug/1890012/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs