Compliation Error when Qt use Mqueue
-
wrote on 25 May 2015, 10:06 last edited by houmingc
Headers and cpp files that compiles successfully is extracted from codeSourcery and inserted into Qt creator IDE. I am using message queue (MQueue)
Compiler error is as below:
make: *** No rule to make target CMsgQ.cc', needed byCMsgQ.o'. Stop.CMsgQ.o: undefined reference to symbol 'mq_send@@GLIBC_2.3.4'
error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status -
Hi,
Can you show your project pro file ?
-
wrote on 26 May 2015, 00:53 last edited by houmingc
QT += core gui
QT += widgets
QT += network
QT +=gui
QT +=gui declarative
QT += xml
---------------------------------------------------------.cc file -----------------
#include <stdio.h>
#include <stdlib.h>
#include <strings.h>
#include <errno.h>error:
strerror was not declared in this scope
memcpy was not declared in this scope -
No
SOURCE += CMsgQ.cc
? -
wrote on 26 May 2015, 15:15 last edited by houmingc
HEADER and SOURCE file is correct, else it will not compile.
I change CMsgQ.cc to CMsgQ.cpp
did a qmake -config serialport.pro -
Are you linking to librt ?
-
wrote on 27 May 2015, 00:58 last edited by
can give an example, how to link and compile
-
win32:LIBS += -lrt
1/8