Error installing sbt for java play framework (openjdk-8-jdk unfulfilled dependencies)

1

Recently I installed oracle-java8-installer and when executing 'java -version' it returned me: java version "1.8.0_121" so I guess that everything is fine. To install jdk 8 follow the steps of the following link: link

To install sbt (to program in the play framework) follow the steps of the official documentation:

echo "deb link /" | sudo tee -a /etc/apt/sources.list.d/sbt.list sudo apt-key adv --keyserver hkp: //keyserver.ubuntu.com: 80 --recv 2EE0EA64E40A89B84B2DF73499E82A75642AC823 sudo apt-get update sudo apt-get install sbt

But I get the following error:

sbt: Depends on: openjdk-8-jdk but it is not installable

and when I try apt-get install openjdk-8-jdk tells me that the package does not have cadidato for its installation.

I tried to download the .deb package for sbt but it shows me the same dependency error.

The only thing I need is to install sbt, however the dependency error with openjdk-8-jdk prevents it. Could someone give me a suggestion?

    
asked by Samuel 15.04.2017 в 03:54
source

1 answer

1

I was able to fix it, since I had to use 8 the solution was to uninstall oracle-java8-installer and reinstall it from the backports repositories of debian 8.

apt-get remove oracle-java8-installer

echo 'deb http://http.debian.net/debian jessie-backports main' >> /etc/apt/sources.list

apt install -t jessie-backports openjdk-8-jre-headless ca-certificates-java openjdk-8-jdk

update-java-alternatives --set java-1.8.0-openjdk-amd64

java -version now returns openjdk version "1.8.0_121"

and finally follow the official steps to install sbt.

    
answered by 15.04.2017 в 04:34