Octave erro de instalação quando o libreadline foi instalado para / usr / local /

4

Instalei o Octave 3.8.1 há alguns meses e descobri que a linha de leitura do GNU não estava funcionando corretamente. Eu tentei reinstalar o Octave 3.8.0, mas o readline GNU não funciona para a versão anterior agora. A linha de leitura do GNU estava funcionando corretamente para o Octave 3.8.0 antes de instalar o 3.8.1. Eu tentei instalar o GNU readline e ncursers, mas o sudo Make não reconhece readline e ncursers existe.

/usr/local/lib/libreadline.so.6: undefined reference to 'tgetstr'
/usr/local/lib/libreadline.so.6: undefined reference to 'tputs'
/usr/local/lib/libreadline.so.6: undefined reference to 'BC'
/usr/local/lib/libreadline.so.6: undefined reference to 'tgetent'
/usr/local/lib/libreadline.so.6: undefined reference to 'tgetflag'
/usr/local/lib/libreadline.so.6: undefined reference to 'tgoto'
/usr/local/lib/libreadline.so.6: undefined reference to 'UP'
/usr/local/lib/libreadline.so.6: undefined reference to 'tgetnum'
/usr/local/lib/libreadline.so.6: undefined reference to 'PC'
collect2: ld returned 1 exit status
make[2]: *** [octave-cli] Error 1
make[2]: Leaving directory '/home/gin/Downloads/octave-3.8.0/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory '/home/gin/Downloads/octave-3.8.0'
make: *** [all] Error 2

Abaixo estão meus pacotes sinápticos de readline instalados no meu computador. Abaixo estão meus pacotes sinápticos de ncursers instalados no meu computador.

Alguém conseguiu resolver esse problema? Obrigado.

Abaixo está o diretório para onde meus arquivos readline estão localizados.

@:/usr/local/lib$ ls
libhistory.a           libpcreposix.a            libreadline.so.6.3.old
libhistory.old         libpcreposix.la           libSDL2-2.0.so.0
libhistory.so          libpcreposix.so           libSDL2-2.0.so.0.1.0
libhistory.so.6        libpcreposix.so.0         libSDL2.a
libhistory.so.6.3      libpcreposix.so.0.0.2     libSDL2.la
libhistory.so.6.3.old  libpcre.so                libSDL2main.a
liblua.a               libpcre.so.1              libSDL2.so
libpcre.a              libpcre.so.1.2.2          libSDL2_test.a
libpcrecpp.a           libreadline.a             lua
libpcrecpp.la          libreadline.old           octave
libpcrecpp.so          libreadline_problem.so.6  pkgconfig
libpcrecpp.so.0        libreadline.so            python2.7
libpcrecpp.so.0.0.0    libreadline.so.6          vmd
libpcre.la             libreadline.so.6.3

Eu tentei a solução de bain. Recebi os seguintes erros de instalação.

$ sudo find /usr/local -name '*octave*' -exec rm -f {} \;
rm: cannot remove '/usr/local/include/octave-3.8.0': Is a directory
rm: cannot remove '/usr/local/include/octave-3.8.0/octave': Is a directory
rm: cannot remove '/usr/local/include/octave-3.8.1': Is a directory
rm: cannot remove '/usr/local/include/octave-3.8.1/octave': Is a directory
rm: cannot remove '/usr/local/libexec/octave': Is a directory
rm: cannot remove '/usr/local/lib/octave': Is a directory
rm: cannot remove '/usr/local/share/octave': Is a directory
rm: cannot remove '/usr/local/share/octave/3.8.1/etc/tests/liboctave': Is a directory
rm: cannot remove '/usr/local/share/octave/3.8.1/etc/tests/libinterp/octave-value': Is a directory
rm: cannot remove '/usr/local/share/octave/3.8.0/etc/tests/liboctave': Is a directory
rm: cannot remove '/usr/local/share/octave/3.8.0/etc/tests/libinterp/octave-value': Is a directory

$ sudo apt-get install octave
...
Errors were encountered while processing:
 octave
E: Sub-process /usr/bin/dpkg returned an error code (1)

Terceira imagem

Quarta Imagem

Abaixo está o readline.so.6 sendo recriado durante o processo de remoção de instalação para a oitava

$:/usr/local/lib$ ls
libhistory.a           libpcrecpp.a         libpcreposix.so        libreadline.so          libSDL2main.a
libhistory.old         libpcrecpp.la        libpcreposix.so.0      libreadline.so.6        libSDL2.so
libhistory.so          libpcrecpp.so        libpcreposix.so.0.0.2  libreadline.so.6.3      libSDL2_test.a
libhistory.so.6        libpcrecpp.so.0      libpcre.so             libreadline.so.6.3.old  lua
libhistory.so.6.3      libpcrecpp.so.0.0.0  libpcre.so.1           libSDL2-2.0.so.0        pkgconfig
libhistory.so.6.3.old  libpcre.la           libpcre.so.1.2.2       libSDL2-2.0.so.0.1.0    python2.7
liblua.a               libpcreposix.a       libreadline.a          libSDL2.a               vmd
libpcre.a              libpcreposix.la      libreadline.old        libSDL2.la
$:/usr/local/lib$ sudo rm /usr/local/lib/libreadline.so.6
$:/usr/local/lib$ ls
libhistory.a           libpcrecpp.a         libpcreposix.so        libreadline.so          libSDL2.so
libhistory.old         libpcrecpp.la        libpcreposix.so.0      libreadline.so.6.3      libSDL2_test.a
libhistory.so          libpcrecpp.so        libpcreposix.so.0.0.2  libreadline.so.6.3.old  lua
libhistory.so.6        libpcrecpp.so.0      libpcre.so             libSDL2-2.0.so.0        pkgconfig
libhistory.so.6.3      libpcrecpp.so.0.0.0  libpcre.so.1           libSDL2-2.0.so.0.1.0    python2.7
libhistory.so.6.3.old  libpcre.la           libpcre.so.1.2.2       libSDL2.a               vmd
liblua.a               libpcreposix.a       libreadline.a          libSDL2.la
libpcre.a              libpcreposix.la      libreadline.old        libSDL2main.a
$:/usr/local/lib$ sudo apt-get purge '.*octave.*'
$:/usr/local/lib$ ls
libhistory.a           libpcrecpp.a         libpcreposix.so        libreadline.so          libSDL2main.a
libhistory.old         libpcrecpp.la        libpcreposix.so.0      libreadline.so.6        libSDL2.so
libhistory.so          libpcrecpp.so        libpcreposix.so.0.0.2  libreadline.so.6.3      libSDL2_test.a
libhistory.so.6        libpcrecpp.so.0      libpcre.so             libreadline.so.6.3.old  lua
libhistory.so.6.3      libpcrecpp.so.0.0.0  libpcre.so.1           libSDL2-2.0.so.0        pkgconfig
libhistory.so.6.3.old  libpcre.la           libpcre.so.1.2.2       libSDL2-2.0.so.0.1.0    python2.7
liblua.a               libpcreposix.a       libreadline.a          libSDL2.a               vmd
libpcre.a              libpcreposix.la      libreadline.old        libSDL2.la
$:/usr/local/lib$ sudo rm /usr/local/lib/libreadline.so.6
$:/usr/local/lib$ ls
libhistory.a           libpcrecpp.a         libpcreposix.so        libreadline.so          libSDL2.so
libhistory.old         libpcrecpp.la        libpcreposix.so.0      libreadline.so.6.3      libSDL2_test.a
libhistory.so          libpcrecpp.so        libpcreposix.so.0.0.2  libreadline.so.6.3.old  lua
libhistory.so.6        libpcrecpp.so.0      libpcre.so             libSDL2-2.0.so.0        pkgconfig
libhistory.so.6.3      libpcrecpp.so.0.0.0  libpcre.so.1           libSDL2-2.0.so.0.1.0    python2.7
libhistory.so.6.3.old  libpcre.la           libpcre.so.1.2.2       libSDL2.a               vmd
liblua.a               libpcreposix.a       libreadline.a          libSDL2.la
libpcre.a              libpcreposix.la      libreadline.old        libSDL2main.a
$:/usr/local/lib$ sudo apt-get install octave
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages were automatically installed and are no longer required:
  units rtkit conky-std libpulsedsp libgsl0ldbl pulseaudio-utils
Use 'apt-get autoremove' to remove them.
The following extra packages will be installed:
  liboctave2 octave-common
Suggested packages:
  octave-info octave-doc octave-htmldoc
The following NEW packages will be installed:
  liboctave2 octave octave-common
0 upgraded, 3 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B/12.3 MB of archives.
After this operation, 43.8 MB of additional disk space will be used.
Do you want to continue [Y/n]? Y
WARNING: The following packages cannot be authenticated!
  liboctave2 octave-common octave
Install these packages without verification [y/N]? y
Selecting previously unselected package liboctave2.
(Reading database ... 368749 files and directories currently installed.)
Unpacking liboctave2 (from .../liboctave2_3.8.1-1ubuntu1~octave1~precise1_amd64.deb) ...
Selecting previously unselected package octave-common.
Unpacking octave-common (from .../octave-common_3.8.1-1ubuntu1~octave1~precise1_all.deb) ...
Selecting previously unselected package octave.
Unpacking octave (from .../octave_3.8.1-1ubuntu1~octave1~precise1_amd64.deb) ...
Processing triggers for menu ...
Processing triggers for desktop-file-utils ...
Processing triggers for bamfdaemon ...
Rebuilding /usr/share/applications/bamf.index...
Processing triggers for gnome-menus ...
Processing triggers for man-db ...
Setting up liboctave2 (3.8.1-1ubuntu1~octave1~precise1) ...
Setting up octave-common (3.8.1-1ubuntu1~octave1~precise1) ...
Setting up octave (3.8.1-1ubuntu1~octave1~precise1) ...
Processing triggers for libc-bin ...
ldconfig deferred processing now taking place
Processing triggers for menu ...
$:/usr/local/lib$ octave
/usr/bin/octave-cli: symbol lookup error: /usr/local/lib/libreadline.so.6: undefined symbol: UP
$:/usr/local/lib$ ls
libhistory.a           libpcrecpp.a         libpcreposix.so        libreadline.so          libSDL2main.a
libhistory.old         libpcrecpp.la        libpcreposix.so.0      libreadline.so.6        libSDL2.so
libhistory.so          libpcrecpp.so        libpcreposix.so.0.0.2  libreadline.so.6.3      libSDL2_test.a
libhistory.so.6        libpcrecpp.so.0      libpcre.so             libreadline.so.6.3.old  lua
libhistory.so.6.3      libpcrecpp.so.0.0.0  libpcre.so.1           libSDL2-2.0.so.0        pkgconfig
libhistory.so.6.3.old  libpcre.la           libpcre.so.1.2.2       libSDL2-2.0.so.0.1.0    python2.7
liblua.a               libpcreposix.a       libreadline.a          libSDL2.a               vmd
libpcre.a              libpcreposix.la      libreadline.old        libSDL2.la
$:/usr/local/lib$ 

O seguinte, abaixo, é o comando sugerido por bain desde 09/05/2014:

$ sudo ppa-purge ppa:octave/stable
Updating packages lists
W: GPG error: http://us.archive.ubuntu.com precise Release: Unknown error executing gpgv
W: GPG error: http://repo.steampowered.com precise Release: Unknown error executing gpgv
W: GPG error: http://dl.google.com stable Release: Unknown error executing gpgv
W: A error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: http://us.archive.ubuntu.com precise-updates Release: Unknown error executing gpgv

W: GPG error: http://us.archive.ubuntu.com precise-backports Release: Unknown error executing gpgv
W: GPG error: http://packages.mate-desktop.org precise Release: Unknown error executing gpgv
W: A error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: http://security.ubuntu.com precise-security Release: Unknown error executing gpgv

W: A error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: http://extras.ubuntu.com precise Release: Unknown error executing gpgv

W: GPG error: http://ppa.launchpad.net precise Release: Unknown error executing gpgv
W: GPG error: http://ppa.launchpad.net precise Release: Unknown error executing gpgv
W: GPG error: http://ppa.launchpad.net precise Release: Unknown error executing gpgv
W: GPG error: http://ppa.launchpad.net precise Release: Unknown error executing gpgv
W: GPG error: http://ppa.launchpad.net precise Release: Unknown error executing gpgv
W: GPG error: http://deb.playonlinux.com maverick Release: Unknown error executing gpgv
W: GPG error: http://ppa.launchpad.net precise Release: Unknown error executing gpgv
W: Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/precise-updates/Release  

W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/precise-security/Release  

W: Failed to fetch http://extras.ubuntu.com/ubuntu/dists/precise/Release  

W: Some index files failed to download. They have been ignored, or old ones used instead.
PPA to be removed: octave stable
comm: file 2 is not in sorted order
Package revert list generated:
 liboctave2/precise octave/precise octave-common/precise

Disabling octave PPA from /etc/apt/sources.list
Updating packages lists
W: A error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: http://security.ubuntu.com precise-security Release: Unknown error executing gpgv

W: GPG error: http://repo.steampowered.com precise Release: Unknown error executing gpgv
W: GPG error: http://dl.google.com stable Release: Unknown error executing gpgv
W: GPG error: http://us.archive.ubuntu.com precise Release: Unknown error executing gpgv
W: A error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: http://us.archive.ubuntu.com precise-updates Release: Unknown error executing gpgv

W: GPG error: http://us.archive.ubuntu.com precise-backports Release: Unknown error executing gpgv
W: GPG error: http://ppa.launchpad.net precise Release: Unknown error executing gpgv
W: A error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: http://extras.ubuntu.com precise Release: Unknown error executing gpgv

W: GPG error: http://deb.playonlinux.com maverick Release: Unknown error executing gpgv
W: GPG error: http://packages.mate-desktop.org precise Release: Unknown error executing gpgv
W: GPG error: http://ppa.launchpad.net precise Release: Unknown error executing gpgv
W: GPG error: http://ppa.launchpad.net precise Release: Unknown error executing gpgv
W: GPG error: http://ppa.launchpad.net precise Release: Unknown error executing gpgv
W: GPG error: http://ppa.launchpad.net precise Release: Unknown error executing gpgv
W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/precise-security/Release  

W: Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/precise-updates/Release  

W: Failed to fetch http://extras.ubuntu.com/ubuntu/dists/precise/Release  

W: Some index files failed to download. They have been ignored, or old ones used instead.
Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: Release 'precise' for 'liboctave2' was not found
Unable to find an archive "precise" for the package "liboctave2"
Unable to find an archive "precise" for the package "liboctave2"
The following packages will be DOWNGRADED:
  octave octave-common 
The following NEW packages will be installed:
  liboctave1{a} 
The following packages will be REMOVED:
  conky-std{u} libgsl0ldbl{u} liboctave2{u} libpulsedsp{u} pulseaudio-utils{u} rtkit{u} units{u} 
0 packages upgraded, 1 newly installed, 2 downgraded, 7 to remove and 0 not upgraded.
Need to get 0 B/11.1 MB of archives. After unpacking 10.6 MB will be freed.
Do you want to continue? [Y/n/?]  Y
WARNING: untrusted versions of the following packages will be installed!

Untrusted packages could compromise your system's security.
You should only proceed with the installation if you are certain that
this is what you want to do.

  octave-common octave liboctave1 

Do you want to ignore this warning and proceed anyway?
To continue, enter "Yes"; to abort, enter "No": Yes
(Reading database ... 370422 files and directories currently installed.)
Removing conky-std ...
Removing libgsl0ldbl ...
Processing triggers for man-db ...
Processing triggers for menu ...
Processing triggers for doc-base ...
Processing 1 removed doc-base file...
Registering documents with scrollkeeper...
Processing triggers for libc-bin ...
ldconfig deferred processing now taking place
Selecting previously unselected package liboctave1.
(Reading database ... 370388 files and directories currently installed.)
Unpacking liboctave1 (from .../liboctave1_3.6.1-1ubuntu1ppa1~precise1_amd64.deb) ...
dpkg: warning: downgrading octave from 3.8.1-1ubuntu1~octave1~precise1 to 3.6.1-1ubuntu1ppa1~precise1.
Preparing to replace octave 3.8.1-1ubuntu1~octave1~precise1 (using .../octave_3.6.1-1ubuntu1ppa1~precise1_amd64.deb) ...
Unpacking replacement octave ...
dpkg: warning: downgrading octave-common from 3.8.1-1ubuntu1~octave1~precise1 to 3.6.1-1ubuntu1ppa1~precise1.
Preparing to replace octave-common 3.8.1-1ubuntu1~octave1~precise1 (using .../octave-common_3.6.1-1ubuntu1ppa1~precise1_all.deb) ...
Unpacking replacement octave-common ...
Processing triggers for menu ...
Processing triggers for man-db ...
Processing triggers for desktop-file-utils ...
Processing triggers for bamfdaemon ...
Rebuilding /usr/share/applications/bamf.index...
Processing triggers for gnome-menus ...
(Reading database ... 369976 files and directories currently installed.)
Removing liboctave2 ...
Removing pulseaudio-utils ...
Removing libpulsedsp ...
Removing rtkit ...
Removing units ...
Processing triggers for libc-bin ...
ldconfig deferred processing now taking place
Processing triggers for man-db ...
Processing triggers for install-info ...
Processing triggers for menu ...
Setting up liboctave1 (3.6.1-1ubuntu1ppa1~precise1) ...
Setting up octave-common (3.6.1-1ubuntu1ppa1~precise1) ...
Installing new version of config file /etc/octave.conf ...
Setting up octave (3.6.1-1ubuntu1ppa1~precise1) ...
octave: symbol lookup error: /usr/local/lib/libreadline.so.6: undefined symbol: UP
dpkg: error processing octave (--configure):
 subprocess installed post-installation script returned error exit status 127
No apport report written because MaxReports is reached already
                                                              Processing triggers for libc-bin ...
ldconfig deferred processing now taking place
Processing triggers for menu ...
Errors were encountered while processing:
 octave
E: Sub-process /usr/bin/dpkg returned an error code (1)
A package failed to install.  Trying to recover:
Setting up octave (3.6.1-1ubuntu1ppa1~precise1) ...
octave: symbol lookup error: /usr/local/lib/libreadline.so.6: undefined symbol: UP
dpkg: error processing octave (--configure):
 subprocess installed post-installation script returned error exit status 127
Processing triggers for menu ...
Errors were encountered while processing:
 octave

Warning:  Something went wrong, packages may not have been reverted
    
por linuxfreebird 03.05.2014 / 03:02

1 resposta

3

Exclua todos os arquivos adicionados a / usr / local. Se você não instalou nenhum outro pacote em / usr / local, faça:

find /usr/local -type f -exec rm -f {} \;

Não faça isso se você tiver instalado outros pacotes em / usr / local . Em vez disso, você terá que passar por / usr / local manualmente e excluir todos os arquivos relacionados à oitava. Um bom começo seria:

find /usr/local -name '*octave*' -exec rm -rf {} \;

Mova sua versão local da libreadline para outro lugar:

mkdir ~/libreadline
mv /usr/local/lib/libreadline* ~/libreadline 

Em seguida, desinstale octave:

apt-get purge '.*octave.*'

Octave no repositório do Ubuntu 12.04 é v3.2, se você quiser a versão estável mais recente (atualmente 3.8.1), adicione o PPA de liberações estáveis do Octave:

add-apt-repository ppa:octave/stable

Verifique se seus outros pacotes estão atualizados:

apt-get update
apt-get dist-upgrade

E reinstale a oitava:

apt-get install octave

Como mtmiller comentou, o Octave dos repositórios funcionará com readline. Você só precisa consertar seu sistema e restaurar o Octave do repositório oficial.

    
por bain 08.05.2014 / 16:18

Tags