I'm trying to follow the Ubuntu OpenCV documentation at OpenCV.
The provided script has a line which executed for some time, taking away more packages than I expected (such as ubuntu-studio video);
sudo apt-get -qq remove ffmpeg x264 libx264-dev
When the script gets to the line below, it bombs;
sudo apt-get -qq install libopencv-dev build-essential checkinstall cmake pkg-config yasm libtiff4-dev libjpeg-dev libjasper-dev libavcodec-dev libavformat-dev libswscale-dev libdc1394-22-dev libxine-dev libgstreamer0.10-dev libgstreamer-plugins-base0.10-dev libv4l-dev python-dev python-numpy libtbb-dev libqt4-dev libgtk2.0-dev libfaac-dev libmp3lame-dev libopencore-amrnb-dev libopencore-amrwb-dev libtheora-dev libvorbis-dev libxvidcore-dev x264 v4l-utils ffmpeg
The error msg is;
E: Unable to correct problems, you have held broken packages.
I've since run Update-Manager, run sudo apt-get updates, rebooted, tried the above script line manually, and still no change.
I've just run
sudo apt-get install -f
and nothing seemed to change. It did mention that some packages were no longer needed and could be removed by apt-get autoremove, so I ran that. It removed a number of packages, so I reran the install command above. Still same problem of held broken packages.
I just ran sudo apt-get -u dist-upgrade
Part of the response was;
The following packages have been kept back: gstreamer0.10-ffmpeg
I'm not sure what that means. I do know that it shows up in my Update-Manager and cannot be checked
I then ran
sudo dpkg --configure -a
and then reran
sudo apt-get -f install
and the package was still not upgraded, though there was this very interesting comment;
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:
gstreamer0.10-ffmpeg : Depends: libavcodec53 (< 5:0) but it is not going to be installed or
libavcodec-extra-53 (< 5:0) but 5:0.7.2-1ubuntu1+codecs1~oneiric2 is to be installed
E: Unable to correct problems, you have held broken packages.
Then I ran
sudo apt-get -u dist-upgrade
It showed I had one held package, so I ran;
sudo apt-get -o Debug::pkgProblemResolver=yes dist-upgrade
It also exited without upgrading the package, so I ran;
sudo apt-get remove --dry-run gstreamer0.10-ffmpeg:i386
And it gave me;
*The following packages will be REMOVED:
arista gstreamer0.10-ffmpeg
0 upgraded, 0 newly installed, 2 to remove and 0 not upgraded.
Remv arista [0.9.7-3ubuntu1]
Remv gstreamer0.10-ffmpeg [0.10.12-1ubuntu1]*
But when I reran
sudo apt-get -u dist-upgrade
It showed the package was still there.
*The following packages have been kept back:
gstreamer0.10-ffmpeg
0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded.*
Update:
Just went into Synaptic PM and completely removed gstreamer0.10-ffmpeg
Reran
sudo apt-get -u dist-upgrade
And was told;
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
However, when I ran the original apt-get to install opencv (first code at the top of this question), it still gave me the same broken package errors.
So I tried
$ cat /etc/apt/sources.list
#
# deb cdrom:[Ubuntu-Studio 11.10 _Oneiric Ocelot_ - Release i386 (20111011.1)]/ oneiric main multiverse restricted universe
# deb cdrom:[Ubuntu-Studio 11.10 _Oneiric Ocelot_ - Release i386 (20111011.1)]/ oneiric main multiverse restricted universe
# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.
deb http://us.archive.ubuntu.com/ubuntu/ precise main restricted
deb-src http://us.archive.ubuntu.com/ubuntu/ precise main restricted
## Major bug fix updates produced after the final release of the
## distribution.
deb http://us.archive.ubuntu.com/ubuntu/ precise-updates main restricted
deb-src http://us.archive.ubuntu.com/ubuntu/ precise-updates main restricted
## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team. Also, please note that software in universe WILL NOT receive any
## review or updates from the Ubuntu security team.
deb http://us.archive.ubuntu.com/ubuntu/ precise universe
deb-src http://us.archive.ubuntu.com/ubuntu/ precise universe
deb http://us.archive.ubuntu.com/ubuntu/ precise-updates universe
deb-src http://us.archive.ubuntu.com/ubuntu/ precise-updates universe
## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team, and may not be under a free licence. Please satisfy yourself as to
## your rights to use the software. Also, please note that software in
## multiverse WILL NOT receive any review or updates from the Ubuntu
## security team.
deb http://us.archive.ubuntu.com/ubuntu/ precise multiverse
deb-src http://us.archive.ubuntu.com/ubuntu/ precise multiverse
deb http://us.archive.ubuntu.com/ubuntu/ precise-updates multiverse
deb-src http://us.archive.ubuntu.com/ubuntu/ precise-updates multiverse
## N.B. software from this repository may not have been tested as
## extensively as that contained in the main release, although it includes
## newer versions of some applications which may provide useful features.
## Also, please note that software in backports WILL NOT receive any review
## or updates from the Ubuntu security team.
deb http://security.ubuntu.com/ubuntu precise-security main restricted
deb-src http://security.ubuntu.com/ubuntu precise-security main restricted
deb http://security.ubuntu.com/ubuntu precise-security universe
deb-src http://security.ubuntu.com/ubuntu precise-security universe
deb http://security.ubuntu.com/ubuntu precise-security multiverse
deb-src http://security.ubuntu.com/ubuntu precise-security multiverse
## Uncomment the following two lines to add software from Canonical's
## 'partner' repository.
## This software is not part of Ubuntu, but is offered by Canonical and the
## respective vendors as a service to Ubuntu users.
deb http://archive.canonical.com/ubuntu precise partner
# deb-src http://archive.canonical.com/ubuntu oneiric partner
## Uncomment the following two lines to add software from Ubuntu's
## 'extras' repository.
## This software is not part of Ubuntu, but is offered by third-party
## developers who want to ship their latest software.
# deb http://extras.ubuntu.com/ubuntu oneiric main
# deb-src http://extras.ubuntu.com/ubuntu oneiric main
# deb http://download.opensuse.org/repositories/home:/popinet/xUbuntu_11.04 ./ # disabled on upgrade to precise
and then;
$
cat /etc/apt/sources.list.d/*
But I don't have enough reputation to post the results here (it says I need at least 10 reputation points to post more than 2 links), so I don't know how to provide the requested feedback.
Then tried;
$ sudo apt-get check
[sudo] password for <abcd>:
Reading package lists... Done
Building dependency tree
Reading state information... Done
However, no resolution of the problem yet.
What else do I need to do?
Will an upgrade to Ubuntu Studio 13.xx solve this problem (or compound it)?