[SOLVED] Error: #include <QLocalSocket> and #include <qlocalsocket.h> not found



  • Hi

    On both includes
    #include <QLocalSocket>
    #include <qlocalsocket.h>
    I get a "No such file or directory" when trying to compile and run on windows. Funny enough, when cross-compiled on linux, there is no error.
    When I hover over it with the mouse it correctly shows me the class message with F1 as well as the path on the header file.
    Strange as well, if I open the localfortuneclient demo, it compiles and runs (on windows) and I don't really see the difference.

    What am I doing wrong?
    I have to add that I am rather new to QT.
    Thanks

    I'd like to add what I am trying to achieve. Maybe there is a good How-To somewhere.
    I have a daemon that acts as Unix Domain Sockets Server that I need to communicate with.
    The server is up and running and I now need to have QT as client and connect to the server and communicate with it.



  • Hi,

    Could you post your .pro file? Maybe you forget to add QT += network in it?

    BR,



  • That was it!
    Thanks a lot. I now have:
    QT += core gui network

    Cheers,
    McL



  • Please add [SOLVED] to the title;)

    So we know it's solved;)



  • I looked for a forum function to set this thread as solved, to no avail.
    I'll do it as you suggested.
    Thanks


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.