How can I trick apt-get to believe that a dependency of an about to be installed package is already installed, so that the referencing package can be installed without installing the dependency ?
Do I have to edit /var/lib/dpkg/status ?
In my real-world case I want to install nagios without having to install mailx and postfix.
I made a shell script /usr/local/bin/mailx that uses msmtp to send mail remotely and linked that to /usr/bin/mailx using update-alternatives.
So I don't need and don't want a local mail infrastructure installed, but nagios3-common depends on bsd-mailx | mailx.
apt-get --force-yes install nagios3-common does not help, neither does defining a negative priority for *mail* packages in /etc/apt/preferences.