Results 1 to 4 of 4

Thread: What Linux libs needed for connectToHost() to work?

  1. #1
    Join Date
    Nov 2008
    Posts
    183
    Thanks
    13
    Thanked 2 Times in 2 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default What Linux libs needed for connectToHost() to work?

    I'm hoping someone knows the answer or can point me to a cheat sheet for this.

    Qt 4.8.x
    Desktop 32-bit Mint 14
    target 32-bit bitbaked Linux

    Using the smtp project library to send email works flawlessly on the desktop. On the embedded target connectToHost() (and the secured version) both fail instantly. Since they do not have a debug version of Qt on the target I cannot step into the call to identify exactly what is missing. I am pretty certain those who baked the cake left something out as has been found previously. Not their fault really. They started really small and have been adding things as the project progressed.

    Yes, I can step through on the desktop and come up with a longer list of function calls to track back, but, was hoping someone had already stumbled into this.

    The really odd part is the library test for SSL comes back as supported, so it does appear they baked in "most" of what was needed.

    Thanks,

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: What Linux libs needed for connectToHost() to work?

    Qt on Linux uses BSD sockets for networking and AFAIK this is part of glibc thus you don't need any extra libraries. Did you verify using system tools (e.g. wireshark) there is no network traffic between the target and its environment?


    This is the list of libraries my QtNetwork links against:
    $ ldd ~/Qt/5.3/gcc_64/lib/libQt5Network.so | awk '{ print $1; }'
    linux-vdso.so.1
    libQt5Core.so.5
    libpthread.so.0
    libstdc++.so.6
    libc.so.6
    libicui18n.so.52
    libicuuc.so.52
    libdl.so.2
    libgthread-2.0.so.0
    librt.so.1
    libglib-2.0.so.0
    libm.so.6
    libgcc_s.so.1
    /lib64/ld-linux-x86-64.so.2
    libicudata.so.52
    libpcre.so.3


    You can see it is just pthreads, icu and pcre apart the other standard libraries (+dynamically loaded OpenSSL in case of using SSL sockets).
    Last edited by wysota; 25th November 2014 at 13:16.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  3. #3
    Join Date
    Jan 2006
    Location
    Graz, Austria
    Posts
    8,416
    Thanks
    37
    Thanked 1,544 Times in 1,494 Posts
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Re: What Linux libs needed for connectToHost() to work?

    Since you mention SSL: does connectToHost() fail or connectToHostEncrypted()?

    Cheers,
    _

  4. #4
    Join Date
    Nov 2008
    Posts
    183
    Thanks
    13
    Thanked 2 Times in 2 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: What Linux libs needed for connectToHost() to work?

    Quote Originally Posted by anda_skoa View Post
    Since you mention SSL: does connectToHost() fail or connectToHostEncrypted()?

    Cheers,
    _
    Both. And the call to determine if SSL is supported actually returns true.

    @wysota,

    Thanks for the list. They had the icu stuff in the build environment, but it did not get deployed to target. Everything else was there. I will send up a flare and get them cranking on a new build.

Similar Threads

  1. Replies: 1
    Last Post: 20th January 2014, 03:02
  2. how to statically compile a program with qt libs?linux platform
    By berlinud in forum Installation and Deployment
    Replies: 8
    Last Post: 27th August 2010, 16:38
  3. why on Linux ,doesn't work?
    By maider in forum Qt Programming
    Replies: 5
    Last Post: 11th March 2010, 08:57
  4. Replies: 3
    Last Post: 18th February 2010, 16:43
  5. How to work on Linux and Eclipse
    By sudheer168 in forum Qt Programming
    Replies: 2
    Last Post: 20th October 2009, 22:35

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.