web-dev-qa-db-fra.com

Comment réparer les paquets LibreOffice cassés

J'ai des "paquets cassés", mais lorsque j'essaie de les réparer dans le gestionnaire de paquets Synaptic, le message d'erreur suivant s'affiche:

dpkg: unrecoverable fatal error, aborting:
 files list file for package `libreoffice-calc' contains empty filename
E: Sub-process /usr/bin/dpkg returned an error code (2)
A package failed to install.  Trying to recover:
dpkg: dependency problems prevent configuration of libreoffice-writer:
 libreoffice-writer depends on libreoffice-core (= 1:3.6.2~rc2-0ubuntu4); however:
  Version of libreoffice-core on system is 1:3.6.2~rc2-0ubuntu3.
 libreoffice-writer depends on libreoffice-base-core (= 1:3.6.2~rc2-0ubuntu4); however:
  Version of libreoffice-base-core on system is 1:3.6.2~rc2-0ubuntu3.

dpkg: error processing libreoffice-writer (--configure):
 dependency problems - leaving unconfigured
dpkg: error processing libreoffice-base-core (--configure):
 Package is in a very bad inconsistent state - you should
 reinstall it before attempting configuration.
dpkg: dependency problems prevent configuration of libreoffice-calc:
 libreoffice-calc depends on libreoffice-core (= 1:3.6.2~rc2-0ubuntu4); however:
  Version of libreoffice-core on system is 1:3.6.2~rc2-0ubuntu3.
 libreoffice-calc depends on libreoffice-base-core (= 1:3.6.2~rc2-0ubuntu4); however:
  Version of libreoffice-base-core on system is 1:3.6.2~rc2-0ubuntu3.

dpkg: error processing libreoffice-calc (--configure):
 dependency problems - leaving unconfigured
Errors were encountered while processing:
 libreoffice-writer
 libreoffice-base-core
 libreoffice-calc

La commande Sudo apt-get install -f me donne ceci:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
Correcting dependencies... Done
The following extra packages will be installed:
  libreoffice-base-core libreoffice-core libreoffice-draw libreoffice-gnome
  libreoffice-gtk libreoffice-impress libreoffice-math python-uno
Suggested packages:
  libreoffice-base libreoffice-evolution
The following packages will be upgraded:
  libreoffice-base-core libreoffice-core libreoffice-draw libreoffice-gnome
  libreoffice-gtk libreoffice-impress libreoffice-math python-uno
8 upgraded, 0 newly installed, 0 to remove and 196 not upgraded.
3 not fully installed or removed.
Need to get 0 B/36.8 MB of archives.
After this operation, 0 B of additional disk space will be used.
Do you want to continue [Y/n]? y
dpkg: unrecoverable fatal error, aborting:
 files list file for package `libreoffice-calc' contains empty filename
E: Sub-process /usr/bin/dpkg returned an error code (2)

En utilisant Sudo apt-get purge libreoffice* suivi de Sudo apt-get install libreoffice, donnez-moi:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies:
 libreoffice : Depends: libreoffice-core (= 1:3.6.2~rc2-0ubuntu4) but 1:3.6.2~rc2-0ubuntu3 is to be installed
               Depends: libreoffice-base but it is not going to be installed
               Depends: ttf-dejavu but it is not going to be installed
               Depends: libreoffice-Java-common (>= 1:3.6.2~rc2~) but it is not going to be installed
 libreoffice-calc : Depends: libreoffice-core (= 1:3.6.2~rc2-0ubuntu4) but 1:3.6.2~rc2-0ubuntu3 is to be installed
                    Depends: libreoffice-base-core (= 1:3.6.2~rc2-0ubuntu4) but 1:3.6.2~rc2-0ubuntu3 is to be installed
 libreoffice-writer : Depends: libreoffice-core (= 1:3.6.2~rc2-0ubuntu4) but 1:3.6.2~rc2-0ubuntu3 is to be installed
                      Depends: libreoffice-base-core (= 1:3.6.2~rc2-0ubuntu4) but 1:3.6.2~rc2-0ubuntu3 is to be installed
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).

Je n'ai AUCUN IDEA quoi faire.

3
Cody Hagman

Essayez de faire Sudo apt-get purge libreoffice*

Ensuite, faites Sudo apt-get install libreoffice


S'il trouve des problèmes de dépendance:

Type

Sudo apt-get purge libreoffice*

Sudo add-apt-repository ppa:libreoffice/ppa

Sudo apt-get update

Sudo apt-get install libreoffice

4
David M. Sousa

Cela l'a résolu pour moi:

Sudo apt-get purge libreoffice *

Une plainte indiquant des dépendances manquantes est apparue et a suggéré de s'exécuter

Sudo apt-get -f install

ce que j'ai fait. Puis encore:

Sudo apt-get purge libreoffice *

suivi par:

Sudo apt-get install libreoffice

0
PBrando

J'ai trouvé cela quand j'ai eu une erreur fatale de dpkg avec le même symptôme - fichier liste vide. . . https://serverfault.com/questions/430682/dpkg-warning-files-list-file-for-package-x-missing

J'ai également ramené le fichier liste de var/lib.

rm /var/lib/dpkg/info/my_missing_package.list.

puis réinstallé

wajig réinstaller synaptic

J'aime wajig - enlève l'effort de se rappeler des appels moins souvent utilisés à dkpg et apt

0
pete_m