Error While loading shared libraries libstdc++.so.5 - linux

I'm attempting to run a program called GlimmerHMM, however when I try to call the program I get this error:
./glimmerhmm_linux
./glimmerhmm_linux: error while loading shared libraries: libstdc++.so.5: cannot open shared object file: No such file or directory
So I tried downloading and installing:
sudo apt-get install libstdc++5
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
html2text libmail-sendmail-perl libsys-hostname-long-perl
Use 'apt-get autoremove' to remove them.
The following NEW packages will be installed: libstdc++5
0 upgraded, 1 newly installed, 0 to remove and 183 not upgraded.
Need to get 255 kB of archives.
After this operation, 1,155 kB of additional disk space will be used.
Get:1 http://archive.ubuntu.com/ubuntu/ precise/universe libstdc++5 amd64 1:3.3.6-25ubuntu1 [255 kB]
Fetched 255 kB in 4s (54.0 kB/s)
Selecting previously unselected package libstdc++5.
(Reading database ... 176303 files and directories currently installed.)
Unpacking libstdc++5 (from .../libstdc++5_1%3a3.3.6-25ubuntu1_amd64.deb) ...
Setting up libstdc++5 (1:3.3.6-25ubuntu1) ...
Processing triggers for libc-bin ...
ldconfig deferred processing now taking place
But I still get the same error when calling the program. Thanks in advance!

Chances are that, if you're running a program old enough to need libstdc++ v5, it's also a 32-bit application, so it can't use the (64-bit) libstdc++5 you installed. Install the ia32-libs package.

I was trying to get one legacy application working and noticed that with Ubuntu 20.04 one needs to add i386 architecture, before one can install i386 libraries.
sudo dpkg --add-architecture i386
sudo apt update
sudo apt install libstdc++5:i386
# libstdc++.so.5 shows up.
ls -la /usr/lib/i386-linux-gnu/libstdc++.so.5
lrwxrwxrwx 1 root root 18 Apr 11 2020 /usr/lib/i386-linux-gnu/libstdc++.so.5 -> libstdc++.so.5.0.7

Related

Unmet dependencies when installing wine 5 or higher in Zorin OS 15.3 [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 1 year ago.
Improve this question
I'm new at Linux and i need to upgrade to the latest of wine, but i got errors:
The following packages have unmet dependencies:
winehq-staging : Depends: wine-staging (= 6.6~groovy-1)
E: Unable to correct problems, you have held broken packages.
I tried it before at
https://linuxize.com/post/how-to-install-wine-on-ubuntu-18-04/
I did many steps:
OS
~$ lsb_release -a
No LSB modules are available.
Distributor ID: Zorin
Description: Zorin OS 15.3
Release: 15
Codename: bionic
Verify 64-bit architecture.
~$ dpkg --print-architecture
amd64
See if 32-bit architecture is installed.
~$ dpkg --print-foreign-architectures
i386
Get and install the repository key.
~$ wget -nc https://dl.winehq.org/wine-builds/winehq.key
‘winehq.key’ saved
~$ sudo apt-key add winehq.key
OK
Add the repository.
~$ sudo apt-add-repository 'deb https://dl.winehq.org/wine-builds/ubuntu/ bionic main'
Fetched 252 kB in 4s (70.6 kB/s)
Reading package lists... Done
Update the package database.
~$ sudo apt update
Fetched 252 kB in 4s (64.5 kB/s)
Reading package lists... Done
Building dependency tree
Reading state information... Done
All packages are up to date.
The next two commands download the libfaudio0 .deb packages into the local active directory.
~$ wget -nc https://download.opensuse.org/repositories/Emulators:/Wine:/Debian/xUbuntu_18.04/amd64/libfaudio0_19.07-0~bionic_amd64.deb
‘libfaudio0_19.07-0~bionic_amd64.deb’ saved
~$ wget -nc https://download.opensuse.org/repositories/Emulators:/Wine:/Debian/xUbuntu_18.04/i386/libfaudio0_19.07-0~bionic_i386.deb
libfaudio0_19.07-0~bionic_i386.deb’ saved
And these two commands do the installations.
~$ sudo apt install ./libfaudio0_19.07-0~bionic_amd64.deb
Use 'sudo apt autoremove' to remove them.
The following packages will be REMOVED:
libfaudio0:i386
The following packages will be DOWNGRADED:
libfaudio0
0 upgraded, 0 newly installed, 1 downgraded, 1 to remove and 0 not upgraded.
Need to get 95.9 kB of archives.
After this operation, 544 kB disk space will be freed.
Do you want to continue? [Y/n] Y
~$ sudo apt install ./libfaudio0_19.07-0~bionic_i386.deb
Use 'sudo apt autoremove' to remove them.
The following NEW packages will be installed:
libfaudio0:i386
0 upgraded, 1 newly installed, 0 to remove and 1 not upgraded.
Need to get 99.5 kB of archives.
After this operation, 300 kB of additional disk space will be used.
Install Wine.
~$ sudo apt install --install-recommends winehq-staging
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:
winehq-staging : Depends: wine-staging (= 6.6~groovy-1)
E: Unable to correct problems, you have held broken packages.
Try to update --fix-missing
~$ sudo apt-get update --fix-missing
Fetched 252 kB in 4s (70.5 kB/s)
Reading package lists... Done
Install wine.
~$ sudo apt install --install-recommends winehq-staging
The following packages have unmet dependencies:
winehq-staging : Depends: wine-staging (= 6.6~groovy-1)
E: Unable to correct problems, you have held broken packages.
Try to update & upgrade
~$ sudo apt update
~$ sudo apt upgrade
2 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 289 kB of archives.
After this operation, 244 kB of additional disk space will be used.
Do you want to continue? [Y/n] Y
Get:1 http://ppa.launchpad.net/cybermax-dexter/sdl2-backport/ubuntu bionic/main i386 libfaudio0 i386 20.10-bionic~1ppa1 [150 kB]
Get:2 http://ppa.launchpad.net/cybermax-dexter/sdl2-backport/ubuntu bionic/main amd64 libfaudio0 amd64 20.10-bionic~1ppa1 [139 kB]
Install wine.
~$ sudo apt install --install-recommends winehq-staging
The following packages have unmet dependencies:
winehq-staging : Depends: wine-staging (= 6.6~groovy-1)
E: Unable to correct problems, you have held broken packages.
I don't know how to solve it, i tried with different Codename: like groovy and others but still same.

Slack installation/boot error: ssh: Could not resolve hostname slack-master Name or Service not known [duplicate]

ssh: Could not resolve hostname slack-master: Name or service not known
rsync: did not see server greeting
rsync error: error starting client-server protocol (code 5) at main.c(1653) [Receiver=3.1.0]
FATAL[slack-getroles]: 'rsync --links --times -e ssh slack-master::slack/etc/roles.conf /var/cache/slack/_role_list' exited 5 at /usr/lib/slack/slack-getroles line 158.
FATAL[slack]: '/usr/lib/slack/slack-getroles' exited 5 at /usr/sbin/slack line 205.
I suspect, this problem has occured from the time I have installed the anaconda package of python. The following steps helped me to resolve the issue.
Step 1: Restart the machine
Step 2: $ sudo apt-get remove slack
Step 3: Download the latest version of slack from Slack website (Find the latest package here - https://slack.com/):
$ wget https://downloads.slack-edge.com/linux_releases/slack-desktop-2.9.0-amd64.deb
Step 4: $ Install the downloaded package using the dpkg utility:
sudo dpkg -i slack-desktop-2.9.0-amd64.deb
In step 4, we will witness the following error:
$ sudo dpkg -i slack-desktop-2.9.0-amd64.deb
(Reading database ... 215272 files and directories currently installed.)
Preparing to unpack slack-desktop-2.9.0-amd64.deb ...
Unpacking slack-desktop (2.9.0) over (2.9.0) ...
dpkg: dependency problems prevent configuration of slack-desktop:
slack-desktop depends on python; however:
Package python is not installed.
dpkg: error processing package slack-desktop (--install):
dependency problems - leaving unconfigured
Processing triggers for gnome-menus (3.13.3-6ubuntu3.1) ...
Processing triggers for desktop-file-utils (0.22-1ubuntu5.1) ...
Processing triggers for bamfdaemon (0.5.3~bzr0+16.04.20160824-0ubuntu1) ...
Rebuilding /usr/share/applications/bamf-2.index...
Processing triggers for mime-support (3.59ubuntu1) ...
Errors were encountered while processing:
slack-desktop
$
To fix this problem: in step 5
Step 5: Install the missing dependencies using: sudo apt-get install -f
$ sudo apt-get install -f
Reading package lists... Done
Building dependency tree
Reading state information... Done
Correcting dependencies... Done
The following additional packages will be installed:
python python2.7
Suggested packages:
python-doc python-tk python2.7-doc
The following NEW packages will be installed:
python python2.7
0 upgraded, 2 newly installed, 0 to remove and 125 not upgraded.
1 not fully installed or removed.
Need to get 361 kB of archives.
After this operation, 1,009 kB of additional disk space will be used.
Do you want to continue? [Y/n] Y
Get:1 http://in.archive.ubuntu.com/ubuntu xenial-updates/main amd64 python2.7 amd64 2.7.12-1ubuntu0~16.04.1 [224 kB]
Get:2 http://in.archive.ubuntu.com/ubuntu xenial/main amd64 python amd64 2.7.11-1 [137 kB]
Fetched 361 kB in 0s (384 kB/s)
Selecting previously unselected package python2.7.
(Reading database ... 215272 files and directories currently installed.)
Preparing to unpack .../python2.7_2.7.12-1ubuntu0~16.04.1_amd64.deb ...
Unpacking python2.7 (2.7.12-1ubuntu0~16.04.1) ...
Selecting previously unselected package python.
Preparing to unpack .../python_2.7.11-1_amd64.deb ...
Unpacking python (2.7.11-1) ...
Processing triggers for gnome-menus (3.13.3-6ubuntu3.1) ...
Processing triggers for desktop-file-utils (0.22-1ubuntu5.1) ...
Processing triggers for bamfdaemon (0.5.3~bzr0+16.04.20160824-0ubuntu1) ...
Rebuilding /usr/share/applications/bamf-2.index...
Processing triggers for mime-support (3.59ubuntu1) ...
Processing triggers for man-db (2.7.5-1) ...
Processing triggers for doc-base (0.10.7) ...
Processing 1 added doc-base file...
Setting up python2.7 (2.7.12-1ubuntu0~16.04.1) ...
Setting up python (2.7.11-1) ...
Setting up slack-desktop (2.9.0) ...
$
I assume you're interested in the slack of https://slack.com. Don't install it through sudo apt install slack: this is another package (if you're interested in this other mysterious slack package, run apt show slack).
To install the slack of https://slack.com, follow the instructions on their website. At the moment, a convenient way is sudo snap install slack --classic, perhaps preceded by sudo apt install snap.
(don't forget to sudo apt remove slack...)
For me All my programs fail if installed through the Ubuntu app store. If I go to the website and manually install their software from their links then everything works fine.
Doing this fixed this exact issue for me for slack. Just went to the slack site and downloaded the .deb file
I had the same issue. Even downloading the slack .deb file from Slack failed.
I tried sudo apt reinstall slack etc but did not work.
SOLUTION: https://snapcraft.io/slack
sudo snap install slack --classic
This solved it for me even while it was still in a "broken" state.
said#said:~$ sudo rm /usr/sbin/slack
said#said:~$ sudo ln -s /usr/lib/slack/slack /usr/sbin/slack
said#said:~$ slack

Unable to install python3-tk on Ubuntu 18.04.2 LTS

I am running Ubuntu 18.04.2 LTS:
user#vmubu01:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 18.04.2 LTS
Release: 18.04
Codename: bionic
And I am unable to install python3-tk using 'apt-get install' command as you can see below:
user#vmubu01:~$ sudo apt-get install python3-tk
Reading package lists... Done
Building dependency tree
Reading state information... Done
Suggested packages:
tix python3-tk-dbg
The following NEW packages will be installed:
python3-tk
0 upgraded, 1 newly installed, 0 to remove and 91 not upgraded.
3 not fully installed or removed.
Need to get 0 B/101 kB of archives.
After this operation, 891 kB of additional disk space will be used.
(Reading database ... 206924 files and directories currently installed.)
Preparing to unpack .../python3-tk_3.6.8-1~18.04_amd64.deb ...
Unpacking python3-tk:amd64 (3.6.8-1~18.04) ...
dpkg: error processing archive /var/cache/apt/archives/python3-tk_3.6.8-1~18.04_amd64.deb (--unpack):
trying to overwrite '/usr/lib/python3.6/tkinter/__init__.py', which is also in package libpython3.6-stdlib:amd64 3.6.8-1+xenial1
dpkg-deb: error: paste subprocess was killed by signal (Broken pipe)
Errors were encountered while processing:
/var/cache/apt/archives/python3-tk_3.6.8-1~18.04_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
I am also unable to install it using pip, see the error below:
user#vmubu01:~$ pip3.6 install python3-tk
Collecting python3-tk
ERROR: Could not find a version that satisfies the requirement python3-tk (from versions: none)
ERROR: No matching distribution found for python3-tk
If I try to run the 'apt --fix-broken install' command I get:
user#vmubu01:~$ sudo apt --fix-broken install
Reading package lists... Done
Building dependency tree
Reading state information... Done
Correcting dependencies... Done
The following additional packages will be installed:
python3-tk
Suggested packages:
tix python3-tk-dbg
The following NEW packages will be installed:
python3-tk
0 upgraded, 1 newly installed, 0 to remove and 91 not upgraded.
3 not fully installed or removed.
Need to get 0 B/101 kB of archives.
After this operation, 891 kB of additional disk space will be used.
Do you want to continue? [Y/n] Y
(Reading database ... 206924 files and directories currently installed.)
Preparing to unpack .../python3-tk_3.6.8-1~18.04_amd64.deb ...
Unpacking python3-tk:amd64 (3.6.8-1~18.04) ...
dpkg: error processing archive /var/cache/apt/archives/python3-tk_3.6.8-1~18.04_amd64.deb (--unpack):
trying to overwrite '/usr/lib/python3.6/tkinter/__init__.py', which is also in package libpython3.6-stdlib:amd64 3.6.8-1+xenial1
Errors were encountered while processing:
/var/cache/apt/archives/python3-tk_3.6.8-1~18.04_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
I please advise
Not sure this solution fits for every situation, but here is one that worked for me.
I had the same issue (except it was with Ubuntu 16.04), also tried what #Column01 wrote in comments:
sudo apt-get install python3.6-tk
Same problem.
But that gave me an idea. Checked:
$ python --version
Python 3.5.2
So the solution was as simple as:
sudo apt-get install python3.5-tk

Error when compiling PostgreSQL on Debian

I'm compiling and installing postgresql on debian, but have some error:
In file included from pg_dump.c:60:0:
pg_backup_archiver.h:44:18: fatal error: zlib.h: No such file or directory
#include <zlib.h>
^
so I want to install zlib1g-dev , however, It reports :
The following NEW packages will be installed:
zlib1g-dev{b}
0 packages upgraded, 1 newly installed, 0 to remove and 64 not upgraded.
Need to get 192 kB of archives. After unpacking 446 kB will be used.
The following packages have unmet dependencies:
zlib1g-dev : Depends: zlib1g (= 1:1.2.3.4.dfsg-3) but 1:1.2.8.dfsg-1 is installed.
The following actions will resolve these dependencies:
Keep the following packages at their current version:
1) zlib1g-dev [Not Installed]
Accept this solution? [Y/n/q/?] y
No packages will be installed, upgraded, or removed.
0 packages upgraded, 0 newly installed, 0 to remove and 64 not upgraded.
Need to get 0 B of archives. After unpacking 0 B will be used.
what should I do? thanks.
since postgresql is already part of debian, why not just use the pre-packaged binary?
if this doesn't fit the bill (for whatever reasons), you can still benefit from the debian packaging effort by installing everything needed to build the debian packages (even if you want to build a psql package that is newer than the one in Debian or has other features, the build will be somehow similar):
# apt-get build-dep postgresql-9.3
and in any case you should make sure that your apt-database is uptodate, so you probably need to run
# apt-get update
before any other step.

sudo apt-get install libao-common

Reading package lists... Done
Building dependency tree
Reading state information... Done
The following NEW packages will be installed:
libao-common
0 upgraded, 1 newly installed, 0 to remove and 52 not upgraded.
4 not fully installed or removed.
Need to get 0 B/11.3 kB of archives.
After this operation, 49.2 kB of additional disk space will be used.
dpkg: regarding .../libao-common_1.1.0-2_armhf.deb containing libao-common:
libao-common conflicts with libao2
libao2 (version 0.8.4-1) is present and unpacked but not configured.
dpkg: error processing /var/cache/apt/archives/libao-common_1.1.0-2_armhf.deb (--unpack):
conflicting packages - not installing libao-common
Errors were encountered while processing:
/var/cache/apt/archives/libao-common_1.1.0-2_armhf.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
Why is conflicting packages not installing libao-common?
It’s on a Raspberry PI with Raspbian.
apt-get -f install doesn't work
root#raspberrypi:~# apt-get -f install
Reading package lists... Done
Building dependency tree
Reading state information... Done
Correcting dependencies... Done
The following extra packages will be installed:
libao-common
The following NEW packages will be installed:
libao-common
0 upgraded, 1 newly installed, 0 to remove and 52 not upgraded.
4 not fully installed or removed.
Need to get 11.3 kB of archives.
After this operation, 49.2 kB of additional disk space will be used.
Do you want to continue [Y/n]? y
Get:1 http://mirrordirector.raspbian.org/raspbian/ wheezy/main libao-common armhf 1.1.0-2 [11.3 kB]
Fetched 11.3 kB in 2s (4,117 B/s)
dpkg: regarding .../libao-common_1.1.0-2_armhf.deb containing libao-common:
libao-common conflicts with libao2
libao2 (version 0.8.4-1) is present and unpacked but not configured.
dpkg: error processing /var/cache/apt/archives/libao-common_1.1.0-2_armhf.deb (--unpack):
conflicting packages - not installing libao-common
Errors were encountered while processing:
/var/cache/apt/archives/libao-common_1.1.0-2_armhf.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
notice that message:
4 not fully installed or removed.
maybe you install other package failed. then the apt tool try to install them again.
so, uninstall these error package first.
sudo apt-get --force-yes remove #your-package-name#
you need to remove the 4 not fully installed or removed package first.
then
sudo apt autoremove
now, try to install the new package again.

Resources