I have this script line to install all packages for a new server.
apt-get install mysql-server openjdk-7-jre-headless tomcat7 tomcat7-admin jsvc apache2 ntp subversion
As you can see it installs Java 7, but Java 6 is also installed because
tomcat7 (indirectly) depends on it. I'm pretty sure I can run Tomcat 7 with Java 7, so I don't want to install two JREs. How can I prevent Java 6 from being installed?
Update: Closer inspection shows that
tomcat-common, depends on
default-jre-headless | java6-runtime-headless | java6-runtime | java-6-runtime(assuming the pipes mean "one of").
java6-runtime-headless, so that dependency should be met.
default-jre-headlessis installed, which installs Java 6.
Why does that happen? Is it because I install them all at once. Should I split it up into 2 calls?
(Ubuntu 12.04 server, 64-bit)