whuang08 / TreeScaper

TreeScaper is distributed under the GNU General Public License.
9 stars 5 forks source link

Cannot launch Linux binary #10

Open josephwb opened 8 years ago

josephwb commented 8 years ago

This is what I get:

./TreeScaper 
./TreeScaper: error while loading shared libraries: libQt5PrintSupport.so.5: cannot open shared object file: No such file or directory

Here is my OS infor:

$ cat /etc/*-release
PRETTY_NAME="Debian GNU/Linux 8 (jessie)"
NAME="Debian GNU/Linux"
VERSION_ID="8"
VERSION="8 (jessie)"
ID=debian
HOME_URL="http://www.debian.org/"
SUPPORT_URL="http://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"
whuang08 commented 8 years ago

We have not tested GUI TreeScaper on Debian yet. We tested GUI TreeScaper on Ubuntu.

jrash commented 8 years ago

Hi Joseph!

Thanks for taking the time to give us feedback on this. We will try to get the binary working for you as we still need to update the instructions on compiling the gui.

It seems that the Ubuntu machines that we tested TreeScaper on all had Qt5 installed. TreeScaper has been linked to shared Qt5 libraries that are neither provided with the release or installed on your system. I have recreated your problem by uninstalling libqt5printsupport5 on my Ubuntu machine. A quick fix would be for you to install Qt5: https://wiki.qt.io/Install_Qt_5_on_Ubuntu. Sorry, the instructions are for Ubuntu, but I guess you can figure out how to do this in Debian. Will you install that and tell us if you can get the binary to run?

Wen, see that you created a startup script "TreeScaper.sh" that adds the TreeScaper directory containing Qt5 libraries to the LD_LIBRARY_PATH, but it seems that all the shared Qt libraries necessary werent included. Dont we need to include all the Qt5 shared libraries and maybe other shared libraries in the release (like those mentioned here: http://doc.qt.io/qt-5/linux-deployment.html). Or could we link the application to static Qt libraries? Here are the libraries TreeScaper depends on:

ldd ./TreeScaper    
    linux-vdso.so.1 =>  (0x00007ffec51bd000)
    libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f7606232000)
    libX11.so.6 => /usr/lib/x86_64-linux-gnu/libX11.so.6 (0x00007f7605efd000)
    libXt.so.6 => /usr/lib/x86_64-linux-gnu/libXt.so.6 (0x00007f7605c97000)
    libQt5PrintSupport.so.5 => /usr/lib/x86_64-linux-gnu/libQt5PrintSupport.so.5 (0x00007f7605a32000)
    libQt5Widgets.so.5 => /usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5 (0x00007f7605209000)
    libQt5WebKit.so.5 => /usr/lib/x86_64-linux-gnu/libQt5WebKit.so.5 (0x00007f7602f3d000)
    libQt5Gui.so.5 => /usr/lib/x86_64-linux-gnu/libQt5Gui.so.5 (0x00007f76028f0000)
    libQt5Core.so.5 => /usr/lib/x86_64-linux-gnu/libQt5Core.so.5 (0x00007f760224a000)
    libGL.so.1 => /usr/lib/nvidia-352/libGL.so.1 (0x00007f7601f1a000)
    libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f7601cfc000)
    libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007f76019f8000)
    libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f76016f2000)
    libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007f76014dc000)
    libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f7601117000)
    /lib64/ld-linux-x86-64.so.2 (0x00007f7606436000)
    libxcb.so.1 => /usr/lib/x86_64-linux-gnu/libxcb.so.1 (0x00007f7600ef8000)
    libSM.so.6 => /usr/lib/x86_64-linux-gnu/libSM.so.6 (0x00007f7600cf0000)
    libICE.so.6 => /usr/lib/x86_64-linux-gnu/libICE.so.6 (0x00007f7600ad4000)
    libgobject-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0 (0x00007f7600883000)
    libglib-2.0.so.0 => /lib/x86_64-linux-gnu/libglib-2.0.so.0 (0x00007f760057b000)
    librt.so.1 => /lib/x86_64-linux-gnu/librt.so.1 (0x00007f7600373000)
    libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x00007f760015a000)
    libXrender.so.1 => /usr/lib/x86_64-linux-gnu/libXrender.so.1 (0x00007f75fff50000)
    libXcomposite.so.1 => /usr/lib/x86_64-linux-gnu/libXcomposite.so.1 (0x00007f75ffd4d000)
    libjpeg.so.8 => /usr/lib/x86_64-linux-gnu/libjpeg.so.8 (0x00007f75ffaf8000)
    libpng12.so.0 => /lib/x86_64-linux-gnu/libpng12.so.0 (0x00007f75ff8d2000)
    libicui18n.so.52 => /usr/lib/x86_64-linux-gnu/libicui18n.so.52 (0x00007f75ff4cb000)
    libicuuc.so.52 => /usr/lib/x86_64-linux-gnu/libicuuc.so.52 (0x00007f75ff152000)
    libxslt.so.1 => /usr/lib/x86_64-linux-gnu/libxslt.so.1 (0x00007f75fef15000)
    libxml2.so.2 => /usr/lib/x86_64-linux-gnu/libxml2.so.2 (0x00007f75febae000)
    libgstreamer-1.0.so.0 => /usr/lib/x86_64-linux-gnu/libgstreamer-1.0.so.0 (0x00007f75fe8aa000)
    libgstapp-1.0.so.0 => /usr/lib/x86_64-linux-gnu/libgstapp-1.0.so.0 (0x00007f75fe69d000)
    libgstbase-1.0.so.0 => /usr/lib/x86_64-linux-gnu/libgstbase-1.0.so.0 (0x00007f75fe445000)
    libgstpbutils-1.0.so.0 => /usr/lib/x86_64-linux-gnu/libgstpbutils-1.0.so.0 (0x00007f75fe21f000)
    libgstvideo-1.0.so.0 => /usr/lib/x86_64-linux-gnu/libgstvideo-1.0.so.0 (0x00007f75fdfd9000)
    libgstaudio-1.0.so.0 => /usr/lib/x86_64-linux-gnu/libgstaudio-1.0.so.0 (0x00007f75fdd8f000)
    libsqlite3.so.0 => /usr/lib/x86_64-linux-gnu/libsqlite3.so.0 (0x00007f75fdad6000)
    libQt5Quick.so.5 => /usr/lib/x86_64-linux-gnu/libQt5Quick.so.5 (0x00007f75fd54b000)
    libQt5Qml.so.5 => /usr/lib/x86_64-linux-gnu/libQt5Qml.so.5 (0x00007f75fcf44000)
    libQt5Network.so.5 => /usr/lib/x86_64-linux-gnu/libQt5Network.so.5 (0x00007f75fcc00000)
    libQt5Sql.so.5 => /usr/lib/x86_64-linux-gnu/libQt5Sql.so.5 (0x00007f75fc9c1000)
    libQt5Positioning.so.5 => /usr/lib/x86_64-linux-gnu/libQt5Positioning.so.5 (0x00007f75fc78c000)
    libQt5Sensors.so.5 => /usr/lib/x86_64-linux-gnu/libQt5Sensors.so.5 (0x00007f75fc551000)
    libharfbuzz.so.0 => /usr/lib/x86_64-linux-gnu/libharfbuzz.so.0 (0x00007f75fc2fc000)
    libnvidia-tls.so.352.63 => /usr/lib/nvidia-352/tls/libnvidia-tls.so.352.63 (0x00007f75fc0f9000)
    libnvidia-glcore.so.352.63 => /usr/lib/nvidia-352/libnvidia-glcore.so.352.63 (0x00007f75f9666000)
    libXext.so.6 => /usr/lib/x86_64-linux-gnu/libXext.so.6 (0x00007f75f9454000)
    libXau.so.6 => /usr/lib/x86_64-linux-gnu/libXau.so.6 (0x00007f75f9250000)
    libXdmcp.so.6 => /usr/lib/x86_64-linux-gnu/libXdmcp.so.6 (0x00007f75f904a000)
    libuuid.so.1 => /lib/x86_64-linux-gnu/libuuid.so.1 (0x00007f75f8e45000)
    libffi.so.6 => /usr/lib/x86_64-linux-gnu/libffi.so.6 (0x00007f75f8c3d000)
    libpcre.so.3 => /lib/x86_64-linux-gnu/libpcre.so.3 (0x00007f75f89ff000)
    libicudata.so.52 => /usr/lib/x86_64-linux-gnu/libicudata.so.52 (0x00007f75f7192000)
    liblzma.so.5 => /lib/x86_64-linux-gnu/liblzma.so.5 (0x00007f75f6f70000)
    libgmodule-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgmodule-2.0.so.0 (0x00007f75f6d6c000)
    liborc-0.4.so.0 => /usr/lib/x86_64-linux-gnu/liborc-0.4.so.0 (0x00007f75f6aea000)
    libgsttag-1.0.so.0 => /usr/lib/x86_64-linux-gnu/libgsttag-1.0.so.0 (0x00007f75f68b2000)
    libfreetype.so.6 => /usr/lib/x86_64-linux-gnu/libfreetype.so.6 (0x00007f75f660f000)
    libgraphite2.so.3 => /usr/lib/x86_64-linux-gnu/libgraphite2.so.3 (0x00007f75f63e9000)
josephwb commented 8 years ago

Thanks @jrash! Ubuntu instructions typically work for debian. I'll give it a try later on today.

jrash commented 8 years ago

You probably do not need to worry about setting up the compiler or the file associations, so you might try skipping those bits at first. You just need to make sure all the needed packages are installed.

jrash commented 8 years ago

Before you install Qt5, will you run 'ldd ./TreeScaper' in your TreeScaper directory and post the results here? This will show us what shared libraries you are missing.

josephwb commented 8 years ago

Sure:

josephwb@wopr:~/Downloads/Linux_TreeScaper_v1.0.0_Binary_2016-08-25$ ldd ./TreeScaper
    linux-vdso.so.1 (0x00007ffd24f34000)
    libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007fe6a41c3000)
    libX11.so.6 => /usr/lib/x86_64-linux-gnu/libX11.so.6 (0x00007fe6a3e80000)
    libXt.so.6 => /usr/lib/x86_64-linux-gnu/libXt.so.6 (0x00007fe6a3c17000)
    libQt5PrintSupport.so.5 => /usr/lib/x86_64-linux-gnu/libQt5PrintSupport.so.5 (0x00007fe6a39a7000)
    libQt5Widgets.so.5 => /usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5 (0x00007fe6a3152000)
    libQt5WebKit.so.5 => /usr/lib/x86_64-linux-gnu/libQt5WebKit.so.5 (0x00007fe6a0b2f000)
    libQt5Gui.so.5 (0x00007fe6a031d000)
    libQt5Core.so.5 (0x00007fe69fbd7000)
    libGL.so.1 => /usr/lib/libGL.so.1 (0x00007fe69f87f000)
    libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007fe69f662000)
    libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007fe69f357000)
    libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007fe69f056000)
    libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007fe69ee40000)
    libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007fe69ea95000)
    /lib64/ld-linux-x86-64.so.2 (0x00007fe6a43c7000)
    libxcb.so.1 => /usr/lib/x86_64-linux-gnu/libxcb.so.1 (0x00007fe69e873000)
    libSM.so.6 => /usr/lib/x86_64-linux-gnu/libSM.so.6 (0x00007fe69e66b000)
    libICE.so.6 => /usr/lib/x86_64-linux-gnu/libICE.so.6 (0x00007fe69e44e000)
    libgobject-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0 (0x00007fe69e1fb000)
    libglib-2.0.so.0 => /lib/x86_64-linux-gnu/libglib-2.0.so.0 (0x00007fe69deec000)
    librt.so.1 => /lib/x86_64-linux-gnu/librt.so.1 (0x00007fe69dce4000)
    libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x00007fe69dac9000)
    libXrender.so.1 => /usr/lib/x86_64-linux-gnu/libXrender.so.1 (0x00007fe69d8bf000)
    libXcomposite.so.1 => /usr/lib/x86_64-linux-gnu/libXcomposite.so.1 (0x00007fe69d6bc000)
    libjpeg.so.62 => /usr/lib/x86_64-linux-gnu/libjpeg.so.62 (0x00007fe69d465000)
    libpng12.so.0 => /usr/lib/x86_64-linux-gnu/libpng12.so.0 (0x00007fe69d23e000)
    libwebp.so.5 => /usr/lib/x86_64-linux-gnu/libwebp.so.5 (0x00007fe69cfe1000)
    libxslt.so.1 => /usr/lib/x86_64-linux-gnu/libxslt.so.1 (0x00007fe69cda2000)
    libxml2.so.2 => /usr/lib/x86_64-linux-gnu/libxml2.so.2 (0x00007fe69ca3b000)
    libgstreamer-0.10.so.0 => /usr/lib/x86_64-linux-gnu/libgstreamer-0.10.so.0 (0x00007fe69c74a000)
    libgstapp-0.10.so.0 => /usr/lib/x86_64-linux-gnu/libgstapp-0.10.so.0 (0x00007fe69c53d000)
    libgstbase-0.10.so.0 => /usr/lib/x86_64-linux-gnu/libgstbase-0.10.so.0 (0x00007fe69c2e3000)
    libgstinterfaces-0.10.so.0 => /usr/lib/x86_64-linux-gnu/libgstinterfaces-0.10.so.0 (0x00007fe69c0d0000)
    libgstpbutils-0.10.so.0 => /usr/lib/x86_64-linux-gnu/libgstpbutils-0.10.so.0 (0x00007fe69beab000)
    libgstvideo-0.10.so.0 => /usr/lib/x86_64-linux-gnu/libgstvideo-0.10.so.0 (0x00007fe69bc8e000)
    libsqlite3.so.0 => /usr/lib/x86_64-linux-gnu/libsqlite3.so.0 (0x00007fe69b9c5000)
    libicui18n.so.52 => /usr/lib/x86_64-linux-gnu/libicui18n.so.52 (0x00007fe69b5b3000)
    libicuuc.so.52 => /usr/lib/x86_64-linux-gnu/libicuuc.so.52 (0x00007fe69b235000)
    libQt5Quick.so.5 => /usr/lib/x86_64-linux-gnu/libQt5Quick.so.5 (0x00007fe69ac7d000)
    libQt5Qml.so.5 => /usr/lib/x86_64-linux-gnu/libQt5Qml.so.5 (0x00007fe69a660000)
    libQt5Network.so.5 => /usr/lib/x86_64-linux-gnu/libQt5Network.so.5 (0x00007fe69a303000)
    libQt5Sql.so.5 => /usr/lib/x86_64-linux-gnu/libQt5Sql.so.5 (0x00007fe69a0c1000)
    libicui18n.so.54 => not found
    libicuuc.so.54 => not found
    libicudata.so.54 => not found
    libgthread-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgthread-2.0.so.0 (0x00007fe699ebf000)
    libnvidia-tls.so.346.46 => /usr/lib/x86_64-linux-gnu/tls/libnvidia-tls.so.346.46 (0x00007fe699cbc000)
    libnvidia-glcore.so.346.46 => /usr/lib/x86_64-linux-gnu/libnvidia-glcore.so.346.46 (0x00007fe696fe3000)
    libXext.so.6 => /usr/lib/x86_64-linux-gnu/libXext.so.6 (0x00007fe696dd1000)
    libXau.so.6 => /usr/lib/x86_64-linux-gnu/libXau.so.6 (0x00007fe696bcd000)
    libXdmcp.so.6 => /usr/lib/x86_64-linux-gnu/libXdmcp.so.6 (0x00007fe6969c8000)
    libuuid.so.1 => /lib/x86_64-linux-gnu/libuuid.so.1 (0x00007fe6967c3000)
    libffi.so.6 => /usr/lib/x86_64-linux-gnu/libffi.so.6 (0x00007fe6965bb000)
    libpcre.so.3 => /lib/x86_64-linux-gnu/libpcre.so.3 (0x00007fe69634d000)
    liblzma.so.5 => /lib/x86_64-linux-gnu/liblzma.so.5 (0x00007fe69612a000)
    libgmodule-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgmodule-2.0.so.0 (0x00007fe695f26000)
    liborc-0.4.so.0 => /usr/lib/x86_64-linux-gnu/liborc-0.4.so.0 (0x00007fe695ca2000)
    libicudata.so.52 => /usr/lib/x86_64-linux-gnu/libicudata.so.52 (0x00007fe694435000)
jrash commented 8 years ago

Interesting. It seems like you have libQt5PrintSupport.so.5 in /usr/lib folder so the dynamic linker should find it. Have you installed Qt5 already? Do you still get this error when trying to run the binary:

./TreeScaper 
./TreeScaper: error while loading shared libraries: libQt5PrintSupport.so.5: cannot open shared object file: No such file or directory

It seems that only the icu54 libraries are missing. Installing the package libicu-dev installs the icu libraries that I need on my Ubuntu machine, so you might try that. If that doesnt work, the most direct way to fix this is to install them manually here: http://www.linuxfromscratch.org/blfs/view/7.7/general/icu.html

I am also seeing people say that reinstalling qt5 using apt has worked for them, so you might try: 'apt-get install qt5-default qttools5-dev-tools' (http://stackoverflow.com/questions/29455836/linkage-against-libqt5core).

It is curious that those libraries are required for you, but are not required for me.

josephwb commented 8 years ago

I only installed:

sudo apt-get install vtk6
sudo apt-get install vtkdata

Perhaps qt5 was a dependency?

I apparently already have libicu-dev installed:

$ sudo apt-get install libicu-dev
Reading package lists... Done
Building dependency tree       
Reading state information... Done
libicu-dev is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

so I am not sure what the problem is. I will try some more tomorrow.

josephwb commented 8 years ago

I can now launch the updated Linux binary, although when it first launches I get an error window:

screenshot from 2016-09-20 13 14 38

although the file seems to be included in the distribution. It seems to work after that.

whuang08 commented 8 years ago

Did you run TreeScaper on the TreeScper directory? If you run TreeScaper from other directory, TreeScaper may not look for dependencies and files from the correct directory.

josephwb commented 8 years ago

I think I just double-clicked it.