Akism90
Akism90

Reputation: 43

How to Get Static Qt Build with any extra module. Eg: error: Unknown module(s) in QT: += serialport

trying to use serialport with a static build of qt and keep getting this error when running qmake or build.

error: Unknown module(s) in QT: += serialport

Using:

Things Attempted:

this is what the .pro file looks like:

QT       += core gui \
         serialport

greaterThan(QT_MAJOR_VERSION, 4): QT += widgets

TARGET = testserialport
TEMPLATE = app

DEFINES += QT_DEPRECATED_WARNINGS

CONFIG += c++11

SOURCES += \
        main.cpp \
        mainwindow.cpp

HEADERS += \
        mainwindow.h

FORMS += \
        mainwindow.ui

qnx: target.path = /tmp/$${TARGET}/bin
else: unix:!android: target.path = /opt/$${TARGET}/bin
!isEmpty(target.path): INSTALLS += target

Expecting to run qmake and be able to use the #include files for serialport and in the future be able to do the same with other modules for static Qt builds.

Cheers

Upvotes: 0

Views: 1310

Answers (0)

Related Questions