Ubuntu – Cannot Install Okular after Ubuntu 14.04 upgrades to 16.04

16.04okularpdfupgrade

I have been trying to install Okular and Kile after my OS upgrades itself from 14.04 to 16.04. However, I get the following error:

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:
 okular : Depends: libokularcore7 (= 4:15.12.3-0ubuntu1) but it is not going to be installed
          Depends: kde-runtime (> 4:4.10) but it is not going to be installed
          Depends: libkio5 (>= 4:4.14) but it is not going to be installed
          Depends: libkparts4 (>= 4:4.14) but it is not going to be installed
          Depends: libkprintutils4 (>= 4:4.14) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

I tried to use aptitude to install again, and this is what it tells me:

The following NEW packages will be installed:
  fonts-dejavu{a} kactivities{a} kate-data{a} katepart{a} kde-runtime{a} kde-runtime-data{a} kde-style-breeze{a} kde-style-breeze-qt4{a} kdelibs-bin{a} kdelibs5-data{a} kdelibs5-plugins{a} 
  kdoctools{a} kpackagelauncherqml{a} kpackagetool5{a} libattica0.4{a} libclucene-core1v5{ab} libdlrestrictions1{a} libkactivities6{a} libkatepartinterfaces4{a} libkcmutils4{a} 
  libkde3support4{a} libkdeclarative5{a} libkdecore5{a} libkdesu5{a} libkdeui5{a} libkdewebkit5{a} libkdnssd4{a} libkemoticons4{a} libkexiv2-11v5{a} libkexiv2-data{a} libkf5activities5{a} 
  libkf5archive5{a} libkf5calendarevents5{a} libkf5declarative-data{a} libkf5declarative5{a} libkf5package-data{a} libkf5package5{a} libkf5plasma5{a} libkf5plasmaquick5{a} 
  libkf5quickaddons5{a} libkf5style5{a} libkfile4{a} libkhtml5{a} libkio5{a} libkjsapi4{a} libkjsembed4{a} libkmediaplayer4{a} libknewstuff3-4{a} libknotifyconfig4{a} libkntlm4{a} 
  libkparts4{a} libkprintutils4{a} libkpty4{a} libkrosscore4{a} libktexteditor4{a} libkxmlrpcclient4{a} libntrack-qt4-1{a} libntrack0{a} libokularcore7{a} libphonon4{a} libplasma3{a} 
  libpolkit-qt-1-1{a} libqca2{a} libqca2-plugins{a} libqimageblitz4{a} libqmobipocket1{a} libqt5quickwidgets5{a} libsolid4{a} libstreamanalyzer0v5{a} libstreams0v5{a} libthreadweaver4{a} 
  libxcb-damage0{a} ntrack-module-libnl-0{a} okular phonon{a} phonon-backend-gstreamer{a} phonon-backend-gstreamer-common{a} plasma-framework{a} plasma-scriptengine-javascript{a} 
  qml-module-org-kde-activities{a} qml-module-org-kde-kquickcontrols{a} qml-module-org-kde-kquickcontrolsaddons{a} qml-module-qtquick-controls{a} 
0 packages upgraded, 83 newly installed, 0 to remove and 0 not upgraded.
Need to get 33.2 MB of archives. After unpacking 120 MB will be used.
The following packages have unmet dependencies:
 libclucene-core1v5 : Conflicts: libclucene-core1 but 2.3.3.4-4build1 is installed.
The following actions will resolve these dependencies:

      Keep the following packages at their current version:
1)      katepart [Not Installed]                           
2)      kde-runtime [Not Installed]                        
3)      kdelibs5-plugins [Not Installed]                   
4)      kdoctools [Not Installed]                          
5)      libclucene-core1v5 [Not Installed]                 
6)      libkatepartinterfaces4 [Not Installed]             
7)      libkde3support4 [Not Installed]                    
8)      libkdewebkit5 [Not Installed]                      
9)      libkemoticons4 [Not Installed]                     
10)     libkfile4 [Not Installed]                          
11)     libkhtml5 [Not Installed]                          
12)     libkio5 [Not Installed]                            
13)     libkmediaplayer4 [Not Installed]                   
14)     libknewstuff3-4 [Not Installed]                    
15)     libknotifyconfig4 [Not Installed]                  
16)     libkparts4 [Not Installed]                         
17)     libkprintutils4 [Not Installed]                    
18)     libktexteditor4 [Not Installed]                    
19)     libkxmlrpcclient4 [Not Installed]                  
20)     libokularcore7 [Not Installed]                     
21)     libplasma3 [Not Installed]                         
22)     libstreamanalyzer0v5 [Not Installed]               
23)     okular [Not Installed]                             
24)     plasma-scriptengine-javascript [Not Installed]     

      Leave the following dependencies unresolved:         
25)     kdelibs5-plugins recommends kde-runtime            


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

Upon accepting this solution by choosing Y, still nothing gets solved.
From my tiny understanding, I think that the problem might arise from this line as cited by aptitude:

25)     kdelibs5-plugins recommends kde-runtime

However, I am not sure and indeed I do not really know what is going on. The hunch is that the problem is kde-related.

I really appreciate any help you guys can extend to me. Thank you!

Best Answer

The following packages have unmet dependencies:
libclucene-core1v5 : Conflicts: libclucene-core1 but 2.3.3.4-4build1 is installed.

It looks like you need to uninstall libclucene-core1, as it conflicts with libclucene-core1v5, and the latter is required in order to install Okular.

Related Question