1

When I run command

sudo apt-get -f 

I get this error

dpkg: error processing gcc-4.8-base:i386 (--configure):
Package is in a very bad inconsistent state - you should
reinstall it before attempting configuration.
Errors were encountered while processing:
gcc-4.8-base:i386
E: Sub-process /usr/bin/dpkg returned an error code (1)

I'm using Ubuntu 13.10

Braiam
  • 67,791
  • 32
  • 179
  • 269
Awis Qirani
  • 11
  • 1
  • 2

3 Answers3

3

Package is in a very bad inconsistent state - you should reinstall it before attempting configuration.

You have to reinstall the package:

sudo apt-get --reinstall install gcc-4.8-base:i386
Braiam
  • 67,791
  • 32
  • 179
  • 269
  • when i run that command , i will get this

    se (= 4.8.1-10ubuntu8) but 4.8.1-10ubuntu9 is to be installed E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).

    – Awis Qirani Dec 02 '13 at 09:42
  • @AwisQirani edit your question, I can't read anything. – Braiam Dec 02 '13 at 13:13
1

I tried both of the answers given above at last after a lot of struggle i found this

sudo dpkg --remove --force-all gcc-4.8-base:i386

if somebody else is looking at this answer for another package then just replace gcc-4.8-base:i386 with the name of the package causing trouble

even after this if your problem is not solved then find all the files named with your package name as a prefix and use

sudo chmod 777 filename

with all of them and then create a copy of them (in case something goes wrong) and then use

sudo rm filename

to delete of them and then run this again

sudo dpkg --remove --force-all gcc-4.8-base:i386
Zanna
  • 70,465
user260214
  • 103
  • 8
-1

Actually the problem is related to gcc 4.8 ,use the following to solve this issue -

Remove gcc-

sudo apt-get purge gcc-4.8

now check -

sudo apt-get -f

for correcting all broken downloads.

Add repository-

sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt-get update

install again -

sudo apt-get install gcc-4.8

hope it will work.

Sukupa91
  • 3,037
  • 2
  • 20
  • 33