Results 1 to 5 of 5

Thread: Qt websocket program not compiling

  1. #1
    Join Date
    Dec 2014
    Posts
    5
    Qt products
    Qt5
    Platforms
    Unix/X11

    Question Qt websocket program not compiling

    I have been working with QT and Ubuntu(14.04) for the last 2 months. I am using QT Creator 3.0.1 which is based on Qt 5.2.1.Currently I am developing a websocket program. When I compile a sample program I get the following error
    /usr/bin/ld: cannot find -lQt5WebSockets

    I have installed the following libraries:
    libqt5webkit5
    libqt5webkit5-dev
    libqt5webkit5:i386
    Please guide me as to how to fix this problem. Thanks and regards

  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: Qt websocket program not compiling

    Do you have libQt5WebSockets.so in your library path?
    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: Qt websocket program not compiling

    Quote Originally Posted by dannykj View Post
    /usr/bin/ld: cannot find -lQt5WebSockets

    I have installed the following libraries:
    libqt5webkit5
    libqt5webkit5-dev
    libqt5webkit5:i386
    If you look at the names you will see that there is a certain difference.
    The library you look for ends in "sockets" the packages you have end in "kit".

    Based on that we could derive that the package you are looking for is
    libqt5websockets5-dev

    A quick search using the package manager confirms that.

    Cheers,
    _

  4. #4
    Join Date
    Dec 2014
    Posts
    5
    Qt products
    Qt5
    Platforms
    Unix/X11

    Unhappy Re: Qt websocket program not compiling

    Quote Originally Posted by wysota View Post
    Do you have libQt5WebSockets.so in your library path?
    No I don't have the library file

  5. #5
    Join Date
    Dec 2014
    Posts
    5
    Qt products
    Qt5
    Platforms
    Unix/X11

    Default Re: Qt websocket program not compiling

    I installed QT 5.3. Later I formed a symbolic link to the library. I also had to update the LD_LIBRARY_PATH to reflect the location of library. Thanks everything works now.

Similar Threads

  1. Websocket SSL
    By manip in forum Qt Programming
    Replies: 1
    Last Post: 28th November 2014, 15:52
  2. Compiling QT program with Wiiyourself error help
    By mumbles in forum Qt Programming
    Replies: 1
    Last Post: 16th January 2013, 23:02
  3. qtwebkit websocket not working
    By schnitzel in forum Qt Programming
    Replies: 0
    Last Post: 12th March 2012, 16:44
  4. Need help compiling a program....
    By MyPianoSucks in forum Qt Programming
    Replies: 8
    Last Post: 3rd January 2011, 00:32
  5. LNK 2019 Error while compiling qt program in VS2008
    By mevkurray in forum Qt for Embedded and Mobile
    Replies: 3
    Last Post: 7th February 2010, 00:29

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.