I develop (or maintain) a package, I've gotten several bug reports along the lines of:
dpkg: error processing /var/cache/apt/archives/libjline-java_1.0-1_all.deb (--unpack):
trying to overwrite '/usr/share/java/jline.jar', which is also in package scala 2.9.2-400
Errors were encountered while processing:
/var/cache/apt/archives/libjline-java_1.0-1_all.deb
but I haven't found a way to prevent/find them before someone hits them. How can I prevent these file conflicts/collisions before this even happens?