How can I tell update manager not to update a package?

I'm using 10.04 and have installed Virtualbox 3.2.10 (not the ose one, but the .deb file from Oracle). It has a dependency on libqt4-opengl which depends on qt version 4.6, but the update manager wants to update to qt 4.7 and remove Virtualbox.

How do I keep it from doing that so that I can get the rest of the updates?


Answering to the question - here is the command for your shell:

echo "libqt4-opengl hold" | dpkg --set-selections

and to revert it back to update-able:

echo "libqt4-opengl install" | dpkg --set-selections

Replace libqt4-opengl with your package's name if I've guessed it incorrectly.


Why you don't install it with the Debian-based Linux distributions process it better and more secure follow the step accord with your ubuntu distribution :

http://www.virtualbox.org/wiki/Linux_Downloads


You can use aptitude to hold a specific package version, this is done like this:

aptitude install <package>=<version>

This will place the package on hold for that given version. To revert simply do

aptitude unhold <package>