1
votes

I am trying to run an executable in Ubuntu 16.04. but it is giving me below error.

error while loading shared libraries: libswscale.so.3: cannot open shared object file: No such file or directory

   :~/ga-projects/gaminganywhere-master/bin$ ldconfig -v
/sbin/ldconfig.real: Path `/lib/powerpc64le-linux-gnu' given more than once
/sbin/ldconfig.real: Path `/usr/lib/powerpc64le-linux-gnu' given more than once
/usr/lib/powerpc64le-linux-gnu/libfakeroot:
    libfakeroot-0.so -> libfakeroot-tcp.so
/home/u0020243/ga-projects/myprog/gaminganywhere/deps.posix/lib:
    libavformat.so.56 -> libavformat.so.56.40.101
    libx265.so.79 -> libx265.so.79
    libavfilter.so.5 -> libavfilter.so.5.40.101
    libswresample.so.1 -> libswresample.so.1.2.101
    libpostproc.so.53 -> libpostproc.so.53.3.100
    libavdevice.so.56 -> libavdevice.so.56.4.100
    libswscale.so.3 -> libswscale.so.3.1.101
    libavcodec.so.56 -> libavcodec.so.56.60.100
    libavutil.so.54 -> libavutil.so.54.31.100
/usr/local/lib:
/lib/powerpc64le-linux-gnu:
    libisc-export.so.160 -> libisc-export.so.160.0.0
    libcidn.so.1 -> libcidn-2.23.so
    libdevmapper.so.1.02.1 -> libdevmapper.so.1.02.1
    libsmartcols.so.1 -> libsmartcols.so.1.1.0
    libpopt.so.0 -> libpopt.so.0.0.0
    libnss_hesiod.so.2 -> libnss_hesiod-2.23.so
    libnss_dns.so.2 -> libnss_dns-2.23.so
    libply.so.4 -> libply.so.4.0.0
    libparted.so.2 -> libparted.so.2.0.1
    libnss_nis.so.2 -> libnss_nis-2.23.so
    libreadline.so.6 -> libreadline.so.6.3
    libext2fs.so.2 -> libext2fs.so.2.4
    libssl.so.1.0.0 -> libssl.so.1.0.0
    libnss_compat.so.2 -> libnss_compat-2.23.so
    libdl.so.2 -> libdl-2.23.so
    libbz2.so.1.0 -> libbz2.so.1.0.4
    libnih.so.1 -> libnih.so.1.0.0
    libply-splash-graphics.so.4 -> libply-splash-graphics.so.4.0.0
    libiptc.so.0 -> libiptc.so.0.0.0
    libpamc.so.0 -> libpamc.so.0.82.1
    libnl-genl-3.so.200 -> libnl-genl-3.so.200.22.0
    libnl-3.so.200 -> libnl-3.so.200.22.0
/sbin/ldconfig.real: /lib/powerpc64le-linux-gnu/ld-2.23.so is the dynamic linker, ignoring

    ld64.so.2 -> ld-2.23.so
    libattr.so.1 -> libattr.so.1.1.0
    libpam.so.0 -> libpam.so.0.83.1
    libnss_nisplus.so.2 -> libnss_nisplus-2.23.so
    libjson-c.so.2 -> libjson-c.so.2.0.0
    libpthread.so.0 -> libpthread-2.23.so
    libtinfo.so.5 -> libtinfo.so.5.9
    libcryptsetup.so.4 -> libcryptsetup.so.4.6.0
    libanl.so.1 -> libanl-2.23.so
    libpng12.so.0 -> libpng12.so.0.54.0
    libthread_db.so.1 -> libthread_db-1.0.so
    libcrypt.so.1 -> libcrypt-2.23.so
    libatm.so.1 -> libatm.so.1.0.0
    libexpat.so.1 -> libexpat.so.1.6.0
    libselinux.so.1 -> libselinux.so.1
    libprocps.so.4 -> libprocps.so.4.0.0
    libip6tc.so.0 -> libip6tc.so.0.1.0
    libnss_files.so.2 -> libnss_files-2.23.so
    libapparmor.so.1 -> libapparmor.so.1.4.0
    libgcc_s.so.1 -> libgcc_s.so.1
    libmemusage.so -> libmemusage.so
    libply-splash-core.so.4 -> libply-splash-core.so.4.0.0
    libdns-export.so.162 -> libdns-export.so.162.1.3
    libncurses.so.5 -> libncurses.so.5.9
    libbsd.so.0 -> libbsd.so.0.8.2
    libz.so.1 -> libz.so.1.2.8
    libpcre.so.3 -> libpcre.so.3.13.2
    libcrypto.so.1.0.0 -> libcrypto.so.1.0.0
    libseccomp.so.2 -> libseccomp.so.2.2.3
    libdbus-1.so.3 -> libdbus-1.so.3.14.6
    libply-boot-client.so.4 -> libply-boot-client.so.4.0.0
    libncursesw.so.5 -> libncursesw.so.5.9
    libnsl.so.1 -> libnsl-2.23.so
    libpam_misc.so.0 -> libpam_misc.so.0.82.0
    libusb-1.0.so.0 -> libusb-1.0.so.0.1.0
    libpcprofile.so -> libpcprofile.so
    libcom_err.so.2 -> libcom_err.so.2.1
    libsepol.so.1 -> libsepol.so.1
    libm.so.6 -> libm-2.23.so
    libmount.so.1 -> libmount.so.1.1.0
    libresolv.so.2 -> libresolv-2.23.so
    libblkid.so.1 -> libblkid.so.1.1.0
    libss.so.2 -> libss.so.2.0
    libcap.so.2 -> libcap.so.2.24
    libulockmgr.so.1 -> libulockmgr.so.1.0.1
    libgcrypt.so.20 -> libgcrypt.so.20.0.5
    libglib-2.0.so.0 -> libglib-2.0.so.0.4800.2
    libSegFault.so -> libSegFault.so
    libip4tc.so.0 -> libip4tc.so.0.1.0
    libusb-0.1.so.4 -> libusb-0.1.so.4.4.4
    libntfs-3g.so.861 -> libntfs-3g.so.861.0.0
    libuuid.so.1 -> libuuid.so.1.3.0
    libkmod.so.2 -> libkmod.so.2.3.0
    libkeyutils.so.1 -> libkeyutils.so.1.5
    libslang.so.2 -> libslang.so.2.3.0
    libxtables.so.11 -> libxtables.so.11.0.0
    liblzo2.so.2 -> liblzo2.so.2.0.0
    liblzma.so.5 -> liblzma.so.5.0.0
    libc.so.6 -> libc-2.23.so
    libfuse.so.2 -> libfuse.so.2.9.4
    libnewt.so.0.52 -> libnewt.so.0.52.18
    libaudit.so.1 -> libaudit.so.1.0.0
    libsystemd.so.0 -> libsystemd.so.0.14.0
    libudev.so.1 -> libudev.so.1.6.4
    libfdisk.so.1 -> libfdisk.so.1.1.0
    libwrap.so.0 -> libwrap.so.0.7.6
    libhistory.so.6 -> libhistory.so.6.3
    libutil.so.1 -> libutil-2.23.so
    libacl.so.1 -> libacl.so.1.1.0
    libBrokenLocale.so.1 -> libBrokenLocale-2.23.so
    libmnl.so.0 -> libmnl.so.0.1.0
    libgpg-error.so.0 -> libgpg-error.so.0.17.0
    libe2p.so.2 -> libe2p.so.2.3
    librt.so.1 -> librt-2.23.so
    libpci.so.3 -> libpci.so.3.3.1
/usr/lib/powerpc64le-linux-gnu:
    librtmp.so.1 -> librtmp.so.1
    libstdc++.so.6 -> libstdc++.so.6.0.21
    libisccfg.so.140 -> libisccfg.so.140.3.0
    libopts.so.25 -> libopts.so.25.16.1
    libcapnp-0.5.3.so -> libcapnp-0.5.3.so
    libgmp.so.10 -> libgmp.so.10.3.0
    libx264.so.148 -> libx264.so.148
    libmpdec.so.2 -> libmpdec.so.2.4.2
    libisccc.so.140 -> libisccc.so.140.0.4
    libicutu.so.55 -> libicutu.so.55.1
    libestr.so.0 -> libestr.so.0.0.0
    libexpatw.so.1 -> libexpatw.so.1.6.0
    libgnutls.so.30 -> libgnutls.so.30.6.2
    libxcb.so.1 -> libxcb.so.1.1.0
    libXdamage.so.1 -> libXdamage.so.1.1.0
    libpcrecpp.so.0 -> libpcrecpp.so.0.0.1
    libmircore.so.1 -> libmircore.so.1
    libboost_system.so.1.58.0 -> libboost_system.so.1.58.0
    libogg.so.0 -> libogg.so.0.8.2
    libboost_filesystem.so.1.58.0 -> libboost_filesystem.so.1.58.0
    libgmodule-2.0.so.0 -> libgmodule-2.0.so.0.4800.2
    libgssapi_krb5.so.2 -> libgssapi_krb5.so.2.2
    libxcb-render.so.0 -> libxcb-render.so.0.0.0
    libXrender.so.1 -> libXrender.so.1.3.0
    libdbus-glib-1.so.2 -> libdbus-glib-1.so.2.3.3
    libgbm.so.1 -> libgbm.so.1.0.0
    libitm.so.1 -> libitm.so.1.0.0
    libxcb-present.so.0 -> libxcb-present.so.0.0.0
    libcurl.so.4 -> libcurl.so.4.4.0
    libdns.so.162 -> libdns.so.162.1.3
    libwind.so.0 -> libwind.so.0.0.0
    libelf.so.1 -> libelf-0.165.so
    libsensors.so.4 -> libsensors.so.4.4.0
    libxvidcore.so.4 -> libxvidcore.so.4.3
    libpng12.so.0 -> libpng.so
    libisl.so.15 -> libisl.so.15.1.1
    libLLVM-5.0.so.1 -> libLLVM-5.0.so.1
    libXfixes.so.3 -> libXfixes.so.3.1.0
    libheimntlm.so.0 -> libheimntlm.so.0.1.0
    libisc.so.160 -> libisc.so.160.0.0
    libhcrypto.so.4 -> libhcrypto.so.4.1.0
    libvorbisenc.so.2 -> libvorbisenc.so.2.0.11
    libprotobuf-lite.so.9 -> libprotobuf-lite.so.9.0.1
    libmircookie.so.2 -> libmircookie.so.2
    libldap_r-2.4.so.2 -> libldap_r-2.4.so.2.10.5
    libfreetype.so.6 -> libfreetype.so.6.12.1
    libhogweed.so.4 -> libhogweed.so.4.2
    libxshmfence.so.1 -> libxshmfence.so.1.0.0
    libpulse-mainloop-glib.so.0 -> libpulse-mainloop-glib.so.0.0.5
    libGeoIP.so.1 -> libGeoIP.so.1.6.9
    libp11-kit.so.0 -> libp11-kit.so.0.1.0
    libopus.so.0 -> libopus.so.0.5.2
    liblwres.so.141 -> liblwres.so.141.0.3
    libicuio.so.55 -> libicuio.so.55.1
    libdrm_radeon.so.1 -> libdrm_radeon.so.1.0.1
    libSDL2_ttf-2.0.so.0 -> libSDL2_ttf.so
    libmircommon.so.7 -> libmircommon.so.7
    libiculx.so.55 -> libiculx.so.55.1
    libgdbm.so.3 -> libgdbm.so.3.0.0
    libwayland-cursor.so.0 -> libwayland-cursor.so.0.0.0
    libdb-5.3.so -> libdb-5.3.so
    libvorbisfile.so.3 -> libvorbisfile.so.3.3.7
    libdrm.so.2 -> libdrm.so.2.4.0
    libICE.so.6 -> libICE.so.6.3.0
    libxcb-shape.so.0 -> libxcb-shape.so.0.0.0
    libnetfilter_conntrack.so.3 -> libnetfilter_conntrack.so.3.5.0
    libpulse-simple.so.0 -> libpulse-simple.so.0.1.0
    libsemanage.so.1 -> libsemanage.so.1
    libapt-inst.so.2.0 -> libapt-inst.so.2.0.0
    libbfd-2.26.1-system.so -> libbfd-2.26.1-system.so
    libcurl-gnutls.so.4 -> libcurl-gnutls.so.4.4.0
    libtasn1.so.6 -> libtasn1.so.6.5.1
    libmpc.so.3 -> libmpc.so.3.0.0
    libeatmydata.so.1 -> libeatmydata.so.1.1.2
    libicudata.so.55 -> libicudata.so.55.1
    libform.so.5 -> libform.so.5.9
    libmirprotobuf.so.3 -> libmirprotobuf.so.3
    libidn.so.11 -> libidn.so.11.6.15
    libaccountsservice.so.0 -> libaccountsservice.so.0.0.0
    libXinerama.so.1 -> libXinerama.so.1.0.0
    libdrm_amdgpu.so.1 -> libdrm_amdgpu.so.1.0.0
    libGLU.so.1 -> libGLU.so.1.3.1
    libarchive.so.13 -> libarchive.so.13.1.2
    libk5crypto.so.3 -> libk5crypto.so.3.1
    libjsoncpp.so.1 -> libjsoncpp.so.1.7.2
    libtheora.so.0 -> libtheora.so.0.3.10
    libmenu.so.5 -> libmenu.so.5.9
    libgio-2.0.so.0 -> libgio-2.0.so.0.4800.2
    libasan.so.2 -> libasan.so.2.0.0
    libXcursor.so.1 -> libXcursor.so.1.0.2
    libX11-xcb.so.1 -> libX11-xcb.so.1.0.0
    libpanel.so.5 -> libpanel.so.5.9
    libpolkit-gobject-1.so.0 -> libpolkit-gobject-1.so.0.0.0
    libapt-pkg.so.5.0 -> libapt-pkg.so.5.0.0
    libXss.so.1 -> libXss.so.1.0.0
    libkrb5.so.3 -> libkrb5.so.3.3
    libpulse.so.0 -> libpulse.so.0.19.0
    libcc1.so.0 -> libcc1.so.0.0.0
    libnettle.so.6 -> libnettle.so.6.2
    librtas.so.1 -> librtas.so.1.3.13
    libpcreposix.so.3 -> libpcreposix.so.3.13.2
    libustr-1.0.so.1 -> libustr-1.0.so.1.0.4
    libkj-0.5.3.so -> libkj-0.5.3.so
    libXtst.so.6 -> libXtst.so.6.1.0
    libFLAC.so.8 -> libFLAC.so.8.3.0
    libgobject-2.0.so.0 -> libgobject-2.0.so.0.4800.2
    libasprintf.so.0 -> libasprintf.so.0.0.0
    libedit.so.2 -> libedit.so.2.0.53
    libmirclient.so.9 -> libmirclient.so.9
    libtic.so.5 -> libtic.so.5.9
    liblber-2.4.so.2 -> liblber-2.4.so.2.10.5
    libprotobuf.so.9 -> libprotobuf.so.9.0.1
    libvpx.so.3 -> libvpx.so.3.0.0
    libglapi.so.0 -> libglapi.so.0.0.0
    libsndio.so.6.1 -> libsndio.so.6.1
    libsqlite3.so.0 -> libsqlite3.so.0.8.6
    libicutest.so.55 -> libicutest.so.55.1
    libxcb-dri3.so.0 -> libxcb-dri3.so.0.0.0
    libcapnpc-0.5.3.so -> libcapnpc-0.5.3.so
    libnuma.so.1 -> libnuma.so.1.0.0
    libicule.so.55 -> libicule.so.55.1
    libXrandr.so.2 -> libXrandr.so.2.2.0
    libformw.so.5 -> libformw.so.5.9
    libnfnetlink.so.0 -> libnfnetlink.so.0.2.0
    libXi.so.6 -> libXi.so.6.1.0
    libbind9.so.140 -> libbind9.so.140.0.10
    libxcb-glx.so.0 -> libxcb-glx.so.0.0.0
    libSDL2-2.0.so.0 -> libSDL2.so
    libXdmcp.so.6 -> libXdmcp.so.6.0.0
    libasyncns.so.0 -> libasyncns.so.0.3.1
    libicui18n.so.55 -> libicui18n.so.55.1
    libmenuw.so.5 -> libmenuw.so.5.9
    libpcap.so.0.8 -> libpcap.so.1.7.4
    libgthread-2.0.so.0 -> libgthread-2.0.so.0.4800.2
    libpcre16.so.3 -> libpcre16.so.3.13.2
    libdebconfclient.so.0 -> libdebconfclient.so.0.0.0
    libXau.so.6 -> libXau.so.6.0.0
    libtxc_dxtn_s2tc.so.0 -> libtxc_dxtn_s2tc.so.0.0.0
    libdns-pkcs11.so.162 -> libdns-pkcs11.so.162.1.3
    libcap-ng.so.0 -> libcap-ng.so.0.0.0
    libwayland-server.so.0 -> libwayland-server.so.0.1.0
    libgssapi.so.3 -> libgssapi.so.3.0.0
    libheimbase.so.1 -> libheimbase.so.1.0.0
    libhx509.so.5 -> libhx509.so.5.0.0
    libsndfile.so.1 -> libsndfile.so.1.0.25
    libffi.so.6 -> libffi.so.6.0.4
    libwayland-client.so.0 -> libwayland-client.so.0.3.0
    libXt.so.6 -> libXt.so.6.0.0
    libroken.so.18 -> libroken.so.18.1.0
    libwayland-egl.so.1 -> libwayland-egl.so.1.0.0
    libXmuu.so.1 -> libXmuu.so.1.0.0
    libubsan.so.0 -> libubsan.so.0.0.0
    libpipeline.so.1 -> libpipeline.so.1.4.1
    libxkbcommon.so.0 -> libxkbcommon.so.0.0.0
    libgnutls-openssl.so.27 -> libgnutls-openssl.so.27.0.2
    libmpfr.so.4 -> libmpfr.so.4.1.4
    libcapnp-rpc-0.5.3.so -> libcapnp-rpc-0.5.3.so
    libXv.so.1 -> libXv.so.1.0.0
    libXxf86vm.so.1 -> libXxf86vm.so.1.0.0
    libkj-async-0.5.3.so -> libkj-async-0.5.3.so
    libapt-private.so.0.0 -> libapt-private.so.0.0.0
    libicuuc.so.55 -> libicuuc.so.55.1
    libfribidi.so.0 -> libfribidi.so.0.3.6
    libtheoraenc.so.1 -> libtheoraenc.so.1.1.2
    libpcre32.so.3 -> libpcre32.so.3.13.2
    libdrm_nouveau.so.2 -> libdrm_nouveau.so.2.0.0
    libasn1.so.8 -> libasn1.so.8.0.0
    libxml2.so.2 -> libxml2.so.2.9.3
    libkrb5.so.26 -> libkrb5.so.26.0.0
    libmp3lame.so.0 -> libmp3lame.so.0.0.0
    libxcb-xfixes.so.0 -> libxcb-xfixes.so.0.0.0
    libxcb-randr.so.0 -> libxcb-randr.so.0.1.0
    libgomp.so.1 -> libgomp.so.1.0.0
    liblz4.so.1 -> liblz4.so.1.7.1
    libmagic.so.1 -> libmagic.so.1.0.0
    libasound.so.2 -> libasound.so.2.0.0
    libisc-pkcs11.so.160 -> libisc-pkcs11.so.160.0.0
    libxcb-dri2.so.0 -> libxcb-dri2.so.0.0.0
    librtasevent.so.1 -> librtasevent.so.1.3.13
    libgdbm_compat.so.3 -> libgdbm_compat.so.3.0.0
    libSM.so.6 -> libSM.so.6.0.1
    libperl.so.5.22 -> libperl.so.5.22.1
    libatomic.so.1 -> libatomic.so.1.1.0
    libopcodes-2.26.1-system.so -> libopcodes-2.26.1-system.so
    libX11.so.6 -> libX11.so.6.3.0
    libxcb-sync.so.1 -> libxcb-sync.so.1.0.0
    libpanelw.so.5 -> libpanelw.so.5.9
    libvorbis.so.0 -> libvorbis.so.0.4.8
    libsasl2.so.2 -> libsasl2.so.2.0.25
    libkrb5support.so.0 -> libkrb5support.so.0.1
    libyaml-0.so.2 -> libyaml-0.so.2.0.4
    libgirepository-1.0.so.1 -> libgirepository-1.0.so.1.0.0
    libtheoradec.so.1 -> libtheoradec.so.1.1.4
    libXext.so.6 -> libXext.so.6.4.0
/usr/lib/powerpc64le-linux-gnu/mesa-egl:
    libEGL.so.1 -> libEGL.so.1.0.0
    libGLESv2.so.2 -> libGLESv2.so.2.0.0
/usr/lib/powerpc64le-linux-gnu/mesa:
    libGL.so.1 -> libGL.so.1.2.0

My shared library path is already set in the ld.so.conf.d and I am also able to see all my shared libraries when I run the ldconfig -v.

I tried some answers from stack overflow but no result. below are the steps I did

  1. used ldd command on the executable. below is the terminal output for that

    :~/ga-projects/gaminganywhere-master/bin$ ldd ga-client linux-vdso64.so.1 (0x00003fffb0040000) libga.so => /home/u0020243/ga-projects/gaminganywhere-master/bin/libga.so (0x00003fffafff0000) libswscale.so.3 => not found libswresample.so.1 => not found libpostproc.so.53 => not found libavdevice.so.56 => not found libavfilter.so.5 => not found libavcodec.so.56 => not found libavformat.so.56 => not found libavutil.so.54 => not found libSDL2_ttf-2.0.so.0 => not found libSDL2-2.0.so.0 => not found libX11.so.6 => /usr/lib/powerpc64le-linux-gnu/libX11.so.6 (0x00003fffafe50000) libXext.so.6 => /usr/lib/powerpc64le-linux-gnu/libXext.so.6 (0x00003fffafe20000) libXtst.so.6 => not found librt.so.1 => /opt/at10.0/lib64/power8/librt.so.1 (0x00003fffafdf0000) libpthread.so.0 => /opt/at10.0/lib64/power8/libpthread.so.0 (0x00003fffafdb0000) libstdc++.so.6 => /opt/at10.0/lib64/power8/libstdc++.so.6 (0x00003fffafb80000) libm.so.6 => /opt/at10.0/lib64/power8/libm.so.6 (0x00003fffafa90000) libgcc_s.so.1 => /opt/at10.0/lib64/power8/libgcc_s.so.1 (0x00003fffafa50000) libc.so.6 => /opt/at10.0/lib64/power8/libc.so.6 (0x00003fffaf860000) libswscale.so.3 => not found libswresample.so.1 => not found libpostproc.so.53 => not found libavdevice.so.56 => not found libavfilter.so.5 => not found libavcodec.so.56 => not found libavformat.so.56 => not found libavutil.so.54 => not found libXtst.so.6 => not found libxcb.so.1 => /usr/lib/powerpc64le-linux-gnu/libxcb.so.1 (0x00003fffaf810000) libdl.so.2 => /opt/at10.0/lib64/power8/libdl.so.2 (0x00003fffaf7e0000) /opt/at10.0/lib64/ld64.so.2 (0x00003fffb0060000) libXau.so.6 => /usr/lib/powerpc64le-linux-gnu/libXau.so.6 (0x00003fffaf7c0000) libXdmcp.so.6 => /usr/lib/powerpc64le-linux-gnu/libXdmcp.so.6 (0x00003fffaf790000)

  2. set the path of shared libraries folder in /etc/environment.

I am out of ways and, Any help will be appreciated.

Thanks and Regards, Satya

1
How do you compile and link your executable? P.S. Post text, not images.Ivan Aksamentov - Drop
Don't use pictures from outside. Copy the text of the error into your question. Read about rpath and this answer to a related question. See also answers to this questionBasile Starynkevitch
@Drop Sorry, I edited my question by replacing images with text. the code is in cpp and have make file to compile it. you can check the code from below link. github.com/chunying/gaminganywhereSatya Harish
@BasileStarynkevitch from my question it is clear that ldconfig is listing all the required shared libraries. And I am using Powerpc. is this is causing the problem?Satya Harish
No, ldd lists many unresolved libraries (not found). You need to fix that. It is not PowerPC specificBasile Starynkevitch

1 Answers

2
votes

You can add the path to the so file to LD_LIBRARY_PATH and check if the executable picks it up and works fine.

export LD_LIBRARY_PATH=pathToFolderWithLib:$LD_LIBRARY_PATH

./"executable"

Reference: http://tldp.org/HOWTO/Program-Library-HOWTO/shared-libraries.html