web-dev-qa-db-ja.com

Debian Stretchにopenjdk-11-jre / jdkをインストールする方法は?

私のサーバーは現在Debian Stretchで実行されています。

Linux *** 4.9.0-8-AMD64#1 SMP Debian 4.9.144-3.1(2019-02-19)x86_64 GNU/Linux

Openjdk-11-jdkをインストールしてみました。これは安定したストレッチの一部ではありません。だから私はソースにバックポートを追加しました 指示

deb http://deb.debian.org/debian ストレッチバックポートメイン

パッケージのインストールは、使用できない依存関係に失敗しました:

536:root:/opt# apt-get update
[...]

537:root:/opt# apt-get -t stretch-backports install "openjdk-11-jdk"
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:
 openjdk-11-jdk : Depends: openjdk-11-jre (= 11.0.3+7-5~bpo9+1) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

538:root:/opt# apt-get -t stretch-backports install "openjdk-11-jre"
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:
 openjdk-11-jre : Depends: libgif7 (>= 5.1) but it is not installable
                  Recommends: libatk-wrapper-Java-jni (>= 0.30.4-0ubuntu2) but it is not installable
E: Unable to correct problems, you have held broken packages.

539:root:/opt# aptitude -t stretch-backports install "openjdk-11-jdk"
The following NEW packages will be installed:
  openjdk-11-jdk openjdk-11-jdk-headless{a} openjdk-11-jre{ab} openjdk-11-jre-headless{a}
0 packages upgraded, 4 newly installed, 0 to remove and 86 not upgraded.
Need to get 223 MB of archives. After unpacking 364 MB will be used.
The following packages have unmet dependencies:
 openjdk-11-jre : Depends: libgif7 (>= 5.1) which is a virtual package and is not provided by any available package

The following actions will resolve these dependencies:

     Keep the following packages at their current version:
1)     openjdk-11-jdk [Not Installed]
2)     openjdk-11-jre [Not Installed]

Accept this solution? [Y/n/q/?] q
Abandoning all efforts to resolve these dependencies.
Abort.

これらの依存関係を解決する方法がわかりません。

更新:

599:root:~# apt policy
Package files:
 100 /var/lib/dpkg/status
     release a=now
 100 http://deb.debian.org/debian stretch-backports/main AMD64 Packages
     release o=Debian Backports,a=stretch-backports,n=stretch-backports,l=Debian Backports,c=main,b=AMD64
     Origin deb.debian.org
 500 http://ftp.de.debian.org/debian stretch-updates/main AMD64 Packages
     release o=Debian,a=oldstable-updates,n=stretch-updates,l=Debian,c=main,b=AMD64
     Origin ftp.de.debian.org
 500 http://security.debian.org stretch/updates/main AMD64 Packages
     release v=9,o=Debian,a=oldstable,n=stretch,l=Debian-Security,c=main,b=AMD64
     Origin security.debian.org
Pinned packages:
1
lg2de

libgif7 パッケージのインストールに必要なstretch/main出力にapt policyリポジトリのエントリが見つかりません。

これを試して:

  • メインリポジトリを/etc/apt/sources.listに追加します。

    deb http://ftp.de.debian.org/debian stretch main
    
  • 次に実行します

    apt-get update
    apt-get -t stretch-backports install openjdk-11-jdk
    
1
Freddy