Ubuntu: How do I fix the package problem I have received after a failed attempt at installing QtOctave?


I installed GNU Octave 3.6.4 today straight after it was released via the commands:

cd ~/octave-3.6.4  ./configure  make  sudo make install  sudo ln -s /home/brentonhorne/octave-3.6.4/run-octave /usr/bin/octave  

which succeeded in installing it (even though without the last line it didn't in the sense that running octave from the command-line didn't call it).

I did this after I had removed the previous version that's currently the only version available in the software centre on Quantal (i.e. GNU Octave 3.6.3).

I then tried to install qtoctave because it was removed with GNU Octave 3.6.3 when I ran sudo apt-get remove octave. Upon running sudo apt-get install -f I received the error:

Reading package lists... Done  Building dependency tree         Reading state information... Done  0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.  1 not fully installed or removed.  After this operation, 0 B of additional disk space will be used.  Setting up octave (3.6.3-2~ppa1~quantal2) ...  error: couldn't read directory /usr/local/share/octave/packages: No such file or directory  error: called from:  error:   /usr/local/share/octave/3.6.4/m/pkg/pkg.m at line 541, column 7  error:   /usr/local/share/octave/3.6.4/m/pkg/pkg.m at line 472, column 25    dpkg: error processing octave (--configure):   subprocess installed post-installation script returned error exit status 1  Processing triggers for menu ...  Errors were encountered while processing:   octave  E: Sub-process /usr/bin/dpkg returned an error code (1)  


Be careful, this can damage your installation!

Find the package which is not properly installed and copy or remember the name of the package:

sudo dpkg --list | grep octave  

Try to remove it (maybe some errors):

sudo dpkg --remove <package>  

Try to purge

sudo dpkg --purge <package>  

Try to do sudo apt-get -f install again.

Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Next Post »