Easy Fix, what you need to do is specify the version of libc6-dev you want to install (the openvz one in this case), and it will install fine.
Heres how to figure out what you want, ok say you are going to do
apt-get install libc6-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
libc6-dev : Depends: libc6 (= 2.15-0ubuntu10.4) but 2.15-0ubuntu10+openvz0 is to be installed
Recommends: gcc but it is not going to be installed or
c-compiler
E: Unable to correct problems, you have held broken packages.
In this case you want it to install the 2.15-0ubuntu10+openvz0 version, try it again specifying the version like this (notice the =version at the end of the line now):
apt-get install libc6-dev=2.15-0ubuntu10+openvz0
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
libc6-dev : Depends: libc-dev-bin (= 2.15-0ubuntu10+openvz0)
Recommends: gcc but it is not going to be installed or
c-compiler
E: Unable to correct problems, you have held broken packages.
As you can see here there wound up being 1 more package that it wanted an 'openvz' version for, so i just added that package onto the apt-get install line again specifying the version
apt-get install libc6-dev=2.15-0ubuntu10+openvz0 libc-dev-bin=2.15-0ubuntu10+openvz0
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
gcc gcc-4.6 libquadmath0 linux-libc-dev manpages-dev
Suggested packages:
gcc-multilib autoconf automake1.9 libtool flex bison gdb gcc-doc gcc-4.6-multilib libmudflap0-4.6-dev gcc-4.6-doc gcc-4.6-locales libgcc1-dbg
libgomp1-dbg libquadmath0-dbg libmudflap0-dbg binutils-gold glibc-doc
The following NEW packages will be installed:
gcc gcc-4.6 libc-dev-bin libc6-dev libquadmath0 linux-libc-dev manpages-dev
0 upgraded, 7 newly installed, 0 to remove and 4 not upgraded.
Need to get 13.6 MB of archives.
After this operation, 33.5 MB of additional disk space will be used.
Do you want to continue [Y/n]?
And now it works!!!
Hope this helped you out , I ran into it myself a few times and knowing how to fix it PROPERLY can help alot, there are alternative ways to get around the error but this is the 'correct' way.
Best Answer
I finally resolved this last night by downloading the package manually from the ondrej repo and installing it with dpkg:
Update: package not found 404,this is correct address: https://launchpad.net/~ondrej/+archive/ubuntu/php5-oldstable/+files/php5-imagick_3.1.0%7Erc2-1%7Eprecise%2B1_amd64.deb