Dependency failure while installing libboost-all-dev on ubuntu core 14.04
Asked Answered
C

3

9

Does someone know why I get the following after "sudo apt-get install libboost-all-dev":

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:
 libboost-all-dev : Depends: libboost-context-dev but it is not going to be installed
                    Depends: libboost-coroutine-dev but it is not going to be installed
                    Depends: libboost-exception-dev but it is not going to be installed
                    Depends: libboost-graph-dev but it is not going to be installed
                    Depends: libboost-graph-parallel-dev but it is not going to be installed
                    Depends: libboost-locale-dev but it is not going to be installed
                    Depends: libboost-log-dev but it is not going to be installed
                    Depends: libboost-math-dev but it is not going to be installed
                    Depends: libboost-mpi-dev but it is not going to be installed
                    Depends: libboost-mpi-python-dev but it is not going to be installed
                    Depends: libboost-random-dev but it is not going to be installed
                    Depends: libboost-signals-dev but it is not going to be installed
                    Depends: libboost-timer-dev but it is not going to be installed
                    Depends: libboost-wave-dev but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

What can I do to change it?

Carnet answered 10/3, 2015 at 7:55 Comment(4)
In such situations, first try to install a dependency. This will show a more verbose problem.Balmacaan
try to use sudo apt-get install -fNorway
The response after trying to install the dependency:The following packages have unmet dependencies: libboost-context1.54-dev : Depends: libboost1.54-dev (= 1.54.0-4ubuntu3) but 1.54.0-4ubuntu3.1 is to be installedCarnet
sudo apt-get install -f -> is not workingCarnet
E
14

You can fix it by using aptitude:

sudo apt-get install aptitude

sudo aptitude install libboost-all-dev

Accept this solution? [Y/n/q/?] n

The following actions will resolve these dependencies:

Downgrade the following packages:

1)     libboost-date-time1.54.0 [1.54.0-4ubuntu3.1 (now) -> 1.54.0-4ubuntu3 (trusty)]

2)     libboost-python1.54.0 [1.54.0-4ubuntu3.1 (now) -> 1.54.0-4ubuntu3 (trusty)]

3)     libboost-system1.54.0 [1.54.0-4ubuntu3.1 (now) -> 1.54.0-4ubuntu3 (trusty)]

4)     libboost-thread1.54.0 [1.54.0-4ubuntu3.1 (now) -> 1.54.0-4ubuntu3 (trusty)]

5)     libpci3 [1:3.2.1-1ubuntu5.1 (now) -> 1:3.2.1-1ubuntu5 (trusty)]

6)     pciutils [1:3.2.1-1ubuntu5.1 (now) -> 1:3.2.1-1ubuntu5 (trusty)]

Accept this solution? [Y/n/q/?] y

The following packages will be DOWNGRADED:
libboost-date-time1.54.0 libboost-python1.54.0 libboost-system1.54.0 
libboost-thread1.54.0 libpci3 pciutils 

Accept this solution? [Y/n/q/?] y

Do you want to continue? [Y/n/?] y
Epigeal answered 12/2, 2017 at 5:45 Comment(0)
T
1

I have just encountered the problem with the exact same package but it is a recurrent problem. I have solved the problem (installing libboost-all-dev) using the following methodology. It is a bit tedious but works fine in around 5 to 10 minutes (depending on the number of dependencies). In fact, you had almost done all the way to the solution.

For each package in your list of unmet dependencies, you have to follow the dependency until you find the package which can not be installed because it has another more recent package available. Then you force its installation in a downgraded version using the = sign with apt-get. For example in your case: apt-get install libboost1.54-dev=1.54.0-4ubuntu3

Once you have done all dependencies, you will be able to install your primary package (libboost-all-dev).

I do not know if there is a better (faster) way to do it.

Theodora answered 24/8, 2015 at 18:53 Comment(0)
A
0

For me it traced back to a newer version of libc6 (fresh install of Ubuntu 20.04.6).

Aptitude gave me a hint:

The following packages have unmet dependencies:
 libc6-dev : Depends: libc6 (= 2.31-0ubuntu9.7) but 2.31-0ubuntu9.9 is installed

dpkg is either not able to compare the version string properly or the dependency is too strict (= rather than >=).

Here's what worked:

sudo apt install libc6=2.31-0ubuntu9.7

This allowed me to install libc6-dev and that unblocked installation of libboost-all-dev.

Anthropologist answered 10/7, 2023 at 3:40 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.