[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Installing Java 8 on a Google Compute Debian (Jessie) instance



On Tue, Dec 18, 2018 at 11:12:00PM +0100, deloptes wrote:
> James H. H. Lampert wrote:
> 
> >> The following packages have unmet dependencies:
> >> openjdk-8-jdk : Depends: openjdk-8-jre (= 8u171-b11-1~bpo8+1) but it is
> >> not going to be installed Depends: openjdk-8-jdk-headless (=
> >> 8u171-b11-1~bpo8+1) but it is not going to be installed E: Unable to
> >> correct problems, you have held broken packages.
> > 
> > which is what I was getting before.
> 
> from my experience you need then to do apt-get install  openjdk-8-jre
> openjdk-8-jdk-headless and they will for sure pull in some dependencies,
> which is why  openjdk-8-jdk does not install automatically.
> 
That will not work either.  The reason the '-t jessie-backports' option
is the right solution is that openjdk-8 requires a newer
ca-certificates-java than what is in jessie.  In a default backports
configuration, packages from the backports repository are ranked lower
than from the stable repository.  Another option would be specify the
precise version of the ca-certificates-java package like this:

apt-get install openjdk-8-jdk ca-certificates-java=<version>

It is also possible to do this:

apt-get install openjdk-8-jdk ca-certificates-java/jessie-backports

But those are less robust than '-t jessie-backports'.  Of course, there
is a possibility that other dependencies get pulled in from
jessie-backports to accomplish the operation, so that must be weighed as
well.

Regards,

-Roberto

-- 
Roberto C. Sánchez


Reply to: