0

I am trying to use QLocalSocket in QT, but I have the error Undefined Reference to QLocalSocket::QLocalSocket(QObject*)

Here is the beginning of the .cpp :

#include "client.h"

Client::Client(QObject *parent) :
  QObject(parent),
  m_socket(new QLocalSocket(this))
{
   tryConnection();
}

And the beginning of the .h

#include <QObject>
#include <QtNetwork/QLocalSocket>

class Client : public QObject
{
  Q_OBJECT
public:
  explicit Client(QObject *parent = 0);
  ~Client();

I work with QT 5.8 on linux.

iAmoric
  • 1,787
  • 3
  • 31
  • 64

0 Answers0