I installed libfreenect on Ubuntu 16.04. Then when I added its libraries in Qt, the following error occurred.
I tried adding libusb-1.0. I typed this in the terminal:
pkg-config libusb-1.0 --libs --cflags -I/usr/include/libusb-1.0 -lusb-1.0
The .pro file:
QT += core QT -= gui
CONFIG += c++11
TARGET = 1 CONFIG += console CONFIG -= app_bundle
TEMPLATE = app
SOURCES += main.cpp
win32:CONFIG(release, debug|release): LIBS += -L$$PWD/../../../usr/local /lib/release/ -lfreenect_sync else:win32:CONFIG(debug, debug|release): LIBS += -L$$PWD/../../../usr/local/lib/debug/ -lfreenect_sync else:unix: LIBS += -L$$PWD/../../../usr/local/lib/ -lfreenect_sync
INCLUDEPATH += $$PWD/../../../usr/local/include DEPENDPATH += $$PWD/../../../usr/local/include
win32-g++:CONFIG(release, debug|release): PRE_TARGETDEPS += $$PWD/../../../usr/local/lib/release/libfreenect_sync.a else:win32-g++:CONFIG(debug, debug|release): PRE_TARGETDEPS += $$PWD/../../../usr/local/lib/debug/libfreenect_sync.a else:win32:!win32-g++:CONFIG(release, debug|release): PRE_TARGETDEPS += $$PWD/../../../usr/local/lib/release/freenect_sync.lib else:win32:!win32-g++:CONFIG(debug, debug|release): PRE_TARGETDEPS += $$PWD/../../../usr/local/lib/debug/freenect_sync.lib else:unix: PRE_TARGETDEPS += $$PWD/../../../usr/local/lib/libfreenect_sync.a
win32:CONFIG(release, debug|release): LIBS += -L$$PWD/../../../usr/local/lib/release/ -lfreenect_sync else:win32:CONFIG(debug, debug|release): LIBS += -L$$PWD/../../../usr/local/lib/debug/ -lfreenect_sync else:unix: LIBS += -L$$PWD/../../../usr/local/lib/ -lfreenect_sync
INCLUDEPATH += $$PWD/../../../usr/local/include DEPENDPATH += $$PWD/../../../usr/local/include
win32:CONFIG(release, debug|release): LIBS += -L$$PWD/../../../usr/local
/lib/release/ -lfreenect else:win32:CONFIG(debug, debug|release): LIBS += -L$$PWD/../../../usr/local/lib/debug/ -lfreenect else:unix: LIBS += -L$$PWD/../../../usr/local/lib/ -lfreenect
INCLUDEPATH += $$PWD/../../../usr/local/include DEPENDPATH += $$PWD/../../../usr/local/include
win32-g++:CONFIG(release, debug|release): PRE_TARGETDEPS += $$PWD/../../../usr/local/lib/release/libfreenect.a else:win32-g++:CONFIG(debug, debug|release): PRE_TARGETDEPS += $$PWD/../../../usr/local/lib/debug/libfreenect.a else:win32:!win32-g++:CONFIG(release, debug|release): PRE_TARGETDEPS += $$PWD/../../../usr/local/lib/release/freenect.lib else:win32:!win32-g++:CONFIG(debug, debug|release): PRE_TARGETDEPS += $$PWD/../../../usr/local/lib/debug/freenect.lib else:unix: PRE_TARGETDEPS += $$PWD/../../../usr/local/lib/libfreenect.a
win32:CONFIG(release, debug|release): LIBS += -L$$PWD/../../../usr/local/lib/release/ -lfreenect else:win32:CONFIG(debug, debug|release): LIBS += -L$$PWD/../../../usr/local/lib/debug/ -lfreenect else:unix: LIBS += -L$$PWD/../../../usr/local/lib/ -lfreenect
INCLUDEPATH += $$PWD/../../../usr/local/include DEPENDPATH += $$PWD/../../../usr/local/include
win32:CONFIG(release, debug|release): LIBS += -L$$PWD/../../../usr/lib/release/ -lusb-1.0 else:win32:CONFIG(debug, debug|release): LIBS += -L$$PWD/../../../usr/lib/debug/ -lusb-1.0 else:unix: LIBS += -L$$PWD/../../../usr/lib/ -lusb-1.0
INCLUDEPATH += $$PWD/../../../usr/include DEPENDPATH += $$PWD/../../../usr/include
But again the same error occurs. How do I solve it?