install qtSerialPort library
I want to install qtserialport in precise1-Ubuntu. I got the source directory using git. next I download lib-qt4-dev and qmake. I ran qmake. it works fine.
but, make fails with the following error:
cd src/ && make -f Makefile
make[1]: Entering directory `/home/saman/5.0.1/serialPortSrc/qtserialport/src'
cd serialport/ && make -f Makefile
make[2]: Entering directory `/home/saman/5.0.1/serialPortSrc/qtserialport/src/serialport'
make[2]: Nothing to be done for `first'.
make[2]: Leaving directory `/home/saman/5.0.1/serialPortSrc/qtserialport/src/serialport'
make[1]: Leaving directory `/home/saman/5.0.1/serialPortSrc/qtserialport/src'
cd examples/ && make -f Makefile
make[1]: Entering directory `/home/saman/5.0.1/serialPortSrc/qtserialport/examples'
cd cenumerator/ && make -f Makefile
make[2]: Entering directory `/home/saman/5.0.1/serialPortSrc/qtserialport/examples/cenumerator'
g++ -Wl,-O1 -o cenumerator main.o -L/usr/lib/i386-linux-gnu -lQtGui -lQtCore -lpthread
main.o: In function `QList<QSerialPortInfo>::free(QListData::Data*) [clone .isra.1]':
main.cpp:(.text+0x47): undefined reference to `QSerialPortInfo::~QSerialPortInfo()'
main.o: In function `QList<QSerialPortInfo>::detach_helper(int)':
main.cpp:(.text._ZN5QListI15QSerialPortInfoE13detach_helperEi[QList<QSerialPortInfo>::detach_helper(int)]+0x68): undefined reference to `QSerialPortInfo::QSerialPortInfo(QSerialPortInfo const&)'
main.cpp:(.text._ZN5QListI15QSerialPortInfoE13detach_helperEi[QList<QSerialPortInfo>::detach_helper(int)]+0xc3): undefined reference to `QSerialPortInfo::~QSerialPortInfo()'
main.o: In function `main':
main.cpp:(.text.startup+0x5e): undefined reference to `QSerialPortInfo::availablePorts()'
main.cpp:(.text.startup+0x10f): undefined reference to `QSerialPortInfo::isBusy() const'
main.cpp:(.text.startup+0x16b): undefined reference to `QSerialPortInfo::hasProductIdentifier() const'
main.cpp:(.text.startup+0x1bb): undefined reference to `QSerialPortInfo::hasVendorIdentifier() const'
main.cpp:(.text.startup+0x212): undefined reference to `QSerialPortInfo::manufacturer() const'
main.cpp:(.text.startup+0x24a): undefined reference to `QSerialPortInfo::description() const'
main.cpp:(.text.startup+0x282): undefined reference to `QSerialPortInfo::systemLocation() const'
main.cpp:(.text.startup+0x2ba): undefined reference to `QSerialPortInfo::portName() const'
main.cpp:(.text.startup+0x644): undefined reference to `QSerialPortInfo::productIdentifier() const'
main.cpp:(.text.startup+0x674): undefined reference to `QSerialPortInfo::vendorIdentifier() const'
collect2: ld returned 1 exit status
make[2]: *** [cenumerator] Error 1
make[2]: Leaving directory `/home/saman/5.0.1/serialPortSrc/qtserialport/examples/cenumerator'
make[1]: *** [sub-cenumerator-make_default-ordered] Error 2
make[1]: Leaving directory `/home/saman/5.0.1/serialPortSrc/qtserialport/examples'
make: *** [sub-examples-make_default-ordered] Error 2
although make fails, I can now include qtserialport header to my project. and about the failure, I checked main.cpp, it includes serialPortSrcInfo.so, this .so file has already been generated when qmake was called. how can I fix the problem?
12.04 compiling qt make
add a comment |
I want to install qtserialport in precise1-Ubuntu. I got the source directory using git. next I download lib-qt4-dev and qmake. I ran qmake. it works fine.
but, make fails with the following error:
cd src/ && make -f Makefile
make[1]: Entering directory `/home/saman/5.0.1/serialPortSrc/qtserialport/src'
cd serialport/ && make -f Makefile
make[2]: Entering directory `/home/saman/5.0.1/serialPortSrc/qtserialport/src/serialport'
make[2]: Nothing to be done for `first'.
make[2]: Leaving directory `/home/saman/5.0.1/serialPortSrc/qtserialport/src/serialport'
make[1]: Leaving directory `/home/saman/5.0.1/serialPortSrc/qtserialport/src'
cd examples/ && make -f Makefile
make[1]: Entering directory `/home/saman/5.0.1/serialPortSrc/qtserialport/examples'
cd cenumerator/ && make -f Makefile
make[2]: Entering directory `/home/saman/5.0.1/serialPortSrc/qtserialport/examples/cenumerator'
g++ -Wl,-O1 -o cenumerator main.o -L/usr/lib/i386-linux-gnu -lQtGui -lQtCore -lpthread
main.o: In function `QList<QSerialPortInfo>::free(QListData::Data*) [clone .isra.1]':
main.cpp:(.text+0x47): undefined reference to `QSerialPortInfo::~QSerialPortInfo()'
main.o: In function `QList<QSerialPortInfo>::detach_helper(int)':
main.cpp:(.text._ZN5QListI15QSerialPortInfoE13detach_helperEi[QList<QSerialPortInfo>::detach_helper(int)]+0x68): undefined reference to `QSerialPortInfo::QSerialPortInfo(QSerialPortInfo const&)'
main.cpp:(.text._ZN5QListI15QSerialPortInfoE13detach_helperEi[QList<QSerialPortInfo>::detach_helper(int)]+0xc3): undefined reference to `QSerialPortInfo::~QSerialPortInfo()'
main.o: In function `main':
main.cpp:(.text.startup+0x5e): undefined reference to `QSerialPortInfo::availablePorts()'
main.cpp:(.text.startup+0x10f): undefined reference to `QSerialPortInfo::isBusy() const'
main.cpp:(.text.startup+0x16b): undefined reference to `QSerialPortInfo::hasProductIdentifier() const'
main.cpp:(.text.startup+0x1bb): undefined reference to `QSerialPortInfo::hasVendorIdentifier() const'
main.cpp:(.text.startup+0x212): undefined reference to `QSerialPortInfo::manufacturer() const'
main.cpp:(.text.startup+0x24a): undefined reference to `QSerialPortInfo::description() const'
main.cpp:(.text.startup+0x282): undefined reference to `QSerialPortInfo::systemLocation() const'
main.cpp:(.text.startup+0x2ba): undefined reference to `QSerialPortInfo::portName() const'
main.cpp:(.text.startup+0x644): undefined reference to `QSerialPortInfo::productIdentifier() const'
main.cpp:(.text.startup+0x674): undefined reference to `QSerialPortInfo::vendorIdentifier() const'
collect2: ld returned 1 exit status
make[2]: *** [cenumerator] Error 1
make[2]: Leaving directory `/home/saman/5.0.1/serialPortSrc/qtserialport/examples/cenumerator'
make[1]: *** [sub-cenumerator-make_default-ordered] Error 2
make[1]: Leaving directory `/home/saman/5.0.1/serialPortSrc/qtserialport/examples'
make: *** [sub-examples-make_default-ordered] Error 2
although make fails, I can now include qtserialport header to my project. and about the failure, I checked main.cpp, it includes serialPortSrcInfo.so, this .so file has already been generated when qmake was called. how can I fix the problem?
12.04 compiling qt make
add a comment |
I want to install qtserialport in precise1-Ubuntu. I got the source directory using git. next I download lib-qt4-dev and qmake. I ran qmake. it works fine.
but, make fails with the following error:
cd src/ && make -f Makefile
make[1]: Entering directory `/home/saman/5.0.1/serialPortSrc/qtserialport/src'
cd serialport/ && make -f Makefile
make[2]: Entering directory `/home/saman/5.0.1/serialPortSrc/qtserialport/src/serialport'
make[2]: Nothing to be done for `first'.
make[2]: Leaving directory `/home/saman/5.0.1/serialPortSrc/qtserialport/src/serialport'
make[1]: Leaving directory `/home/saman/5.0.1/serialPortSrc/qtserialport/src'
cd examples/ && make -f Makefile
make[1]: Entering directory `/home/saman/5.0.1/serialPortSrc/qtserialport/examples'
cd cenumerator/ && make -f Makefile
make[2]: Entering directory `/home/saman/5.0.1/serialPortSrc/qtserialport/examples/cenumerator'
g++ -Wl,-O1 -o cenumerator main.o -L/usr/lib/i386-linux-gnu -lQtGui -lQtCore -lpthread
main.o: In function `QList<QSerialPortInfo>::free(QListData::Data*) [clone .isra.1]':
main.cpp:(.text+0x47): undefined reference to `QSerialPortInfo::~QSerialPortInfo()'
main.o: In function `QList<QSerialPortInfo>::detach_helper(int)':
main.cpp:(.text._ZN5QListI15QSerialPortInfoE13detach_helperEi[QList<QSerialPortInfo>::detach_helper(int)]+0x68): undefined reference to `QSerialPortInfo::QSerialPortInfo(QSerialPortInfo const&)'
main.cpp:(.text._ZN5QListI15QSerialPortInfoE13detach_helperEi[QList<QSerialPortInfo>::detach_helper(int)]+0xc3): undefined reference to `QSerialPortInfo::~QSerialPortInfo()'
main.o: In function `main':
main.cpp:(.text.startup+0x5e): undefined reference to `QSerialPortInfo::availablePorts()'
main.cpp:(.text.startup+0x10f): undefined reference to `QSerialPortInfo::isBusy() const'
main.cpp:(.text.startup+0x16b): undefined reference to `QSerialPortInfo::hasProductIdentifier() const'
main.cpp:(.text.startup+0x1bb): undefined reference to `QSerialPortInfo::hasVendorIdentifier() const'
main.cpp:(.text.startup+0x212): undefined reference to `QSerialPortInfo::manufacturer() const'
main.cpp:(.text.startup+0x24a): undefined reference to `QSerialPortInfo::description() const'
main.cpp:(.text.startup+0x282): undefined reference to `QSerialPortInfo::systemLocation() const'
main.cpp:(.text.startup+0x2ba): undefined reference to `QSerialPortInfo::portName() const'
main.cpp:(.text.startup+0x644): undefined reference to `QSerialPortInfo::productIdentifier() const'
main.cpp:(.text.startup+0x674): undefined reference to `QSerialPortInfo::vendorIdentifier() const'
collect2: ld returned 1 exit status
make[2]: *** [cenumerator] Error 1
make[2]: Leaving directory `/home/saman/5.0.1/serialPortSrc/qtserialport/examples/cenumerator'
make[1]: *** [sub-cenumerator-make_default-ordered] Error 2
make[1]: Leaving directory `/home/saman/5.0.1/serialPortSrc/qtserialport/examples'
make: *** [sub-examples-make_default-ordered] Error 2
although make fails, I can now include qtserialport header to my project. and about the failure, I checked main.cpp, it includes serialPortSrcInfo.so, this .so file has already been generated when qmake was called. how can I fix the problem?
12.04 compiling qt make
I want to install qtserialport in precise1-Ubuntu. I got the source directory using git. next I download lib-qt4-dev and qmake. I ran qmake. it works fine.
but, make fails with the following error:
cd src/ && make -f Makefile
make[1]: Entering directory `/home/saman/5.0.1/serialPortSrc/qtserialport/src'
cd serialport/ && make -f Makefile
make[2]: Entering directory `/home/saman/5.0.1/serialPortSrc/qtserialport/src/serialport'
make[2]: Nothing to be done for `first'.
make[2]: Leaving directory `/home/saman/5.0.1/serialPortSrc/qtserialport/src/serialport'
make[1]: Leaving directory `/home/saman/5.0.1/serialPortSrc/qtserialport/src'
cd examples/ && make -f Makefile
make[1]: Entering directory `/home/saman/5.0.1/serialPortSrc/qtserialport/examples'
cd cenumerator/ && make -f Makefile
make[2]: Entering directory `/home/saman/5.0.1/serialPortSrc/qtserialport/examples/cenumerator'
g++ -Wl,-O1 -o cenumerator main.o -L/usr/lib/i386-linux-gnu -lQtGui -lQtCore -lpthread
main.o: In function `QList<QSerialPortInfo>::free(QListData::Data*) [clone .isra.1]':
main.cpp:(.text+0x47): undefined reference to `QSerialPortInfo::~QSerialPortInfo()'
main.o: In function `QList<QSerialPortInfo>::detach_helper(int)':
main.cpp:(.text._ZN5QListI15QSerialPortInfoE13detach_helperEi[QList<QSerialPortInfo>::detach_helper(int)]+0x68): undefined reference to `QSerialPortInfo::QSerialPortInfo(QSerialPortInfo const&)'
main.cpp:(.text._ZN5QListI15QSerialPortInfoE13detach_helperEi[QList<QSerialPortInfo>::detach_helper(int)]+0xc3): undefined reference to `QSerialPortInfo::~QSerialPortInfo()'
main.o: In function `main':
main.cpp:(.text.startup+0x5e): undefined reference to `QSerialPortInfo::availablePorts()'
main.cpp:(.text.startup+0x10f): undefined reference to `QSerialPortInfo::isBusy() const'
main.cpp:(.text.startup+0x16b): undefined reference to `QSerialPortInfo::hasProductIdentifier() const'
main.cpp:(.text.startup+0x1bb): undefined reference to `QSerialPortInfo::hasVendorIdentifier() const'
main.cpp:(.text.startup+0x212): undefined reference to `QSerialPortInfo::manufacturer() const'
main.cpp:(.text.startup+0x24a): undefined reference to `QSerialPortInfo::description() const'
main.cpp:(.text.startup+0x282): undefined reference to `QSerialPortInfo::systemLocation() const'
main.cpp:(.text.startup+0x2ba): undefined reference to `QSerialPortInfo::portName() const'
main.cpp:(.text.startup+0x644): undefined reference to `QSerialPortInfo::productIdentifier() const'
main.cpp:(.text.startup+0x674): undefined reference to `QSerialPortInfo::vendorIdentifier() const'
collect2: ld returned 1 exit status
make[2]: *** [cenumerator] Error 1
make[2]: Leaving directory `/home/saman/5.0.1/serialPortSrc/qtserialport/examples/cenumerator'
make[1]: *** [sub-cenumerator-make_default-ordered] Error 2
make[1]: Leaving directory `/home/saman/5.0.1/serialPortSrc/qtserialport/examples'
make: *** [sub-examples-make_default-ordered] Error 2
although make fails, I can now include qtserialport header to my project. and about the failure, I checked main.cpp, it includes serialPortSrcInfo.so, this .so file has already been generated when qmake was called. how can I fix the problem?
12.04 compiling qt make
12.04 compiling qt make
asked Apr 24 '13 at 13:49
SamSam
1831311
1831311
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
AFAIK it is based on Qt5+.
I am using Qtserial in my project (pilotnavigator). My QTSDK 5+ is installed locally (not via apt). These are the instructions.
- Copy qtplayground-qtserialport folder into a local folder (preferably where your Qt projects are). Example:
~/yourqtprojectfolder/pilotnavigator/qtplayground-qtserialport
- Create a build folder at the same level called qtplayground-qtserialport-build in pilotnavigator folder. Example:
~/yourqtprojectfolder/pilotnavigator/qtplayground-qtserialport-build
Find out where qmake lives. Normaly it is located in your Qt5 folder, probably ~/Qt5x.x.x/5.x.x/gcc_64/bin
Open a Linux Terminal
cd to the qtplayground-qtserialport-build folder. Example cd ~/yourqtprojectfolder/pilotnavigator/qtplayground-qtserialport-build
run qmake. Example:
~/Qt5x.x.x/5.x.x/gcc_64/bin/qmake ~/yourqtprojectfolder/pilotnavigator/qtplayground-qtserialport/qtserialport.pro
make
(If you get an error concerning missing file libudev.h, you need to install the libudev-dev library, e.g. sudo apt-get install libudev-dev
)
sudo make install
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "89"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f284952%2finstall-qtserialport-library%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
AFAIK it is based on Qt5+.
I am using Qtserial in my project (pilotnavigator). My QTSDK 5+ is installed locally (not via apt). These are the instructions.
- Copy qtplayground-qtserialport folder into a local folder (preferably where your Qt projects are). Example:
~/yourqtprojectfolder/pilotnavigator/qtplayground-qtserialport
- Create a build folder at the same level called qtplayground-qtserialport-build in pilotnavigator folder. Example:
~/yourqtprojectfolder/pilotnavigator/qtplayground-qtserialport-build
Find out where qmake lives. Normaly it is located in your Qt5 folder, probably ~/Qt5x.x.x/5.x.x/gcc_64/bin
Open a Linux Terminal
cd to the qtplayground-qtserialport-build folder. Example cd ~/yourqtprojectfolder/pilotnavigator/qtplayground-qtserialport-build
run qmake. Example:
~/Qt5x.x.x/5.x.x/gcc_64/bin/qmake ~/yourqtprojectfolder/pilotnavigator/qtplayground-qtserialport/qtserialport.pro
make
(If you get an error concerning missing file libudev.h, you need to install the libudev-dev library, e.g. sudo apt-get install libudev-dev
)
sudo make install
add a comment |
AFAIK it is based on Qt5+.
I am using Qtserial in my project (pilotnavigator). My QTSDK 5+ is installed locally (not via apt). These are the instructions.
- Copy qtplayground-qtserialport folder into a local folder (preferably where your Qt projects are). Example:
~/yourqtprojectfolder/pilotnavigator/qtplayground-qtserialport
- Create a build folder at the same level called qtplayground-qtserialport-build in pilotnavigator folder. Example:
~/yourqtprojectfolder/pilotnavigator/qtplayground-qtserialport-build
Find out where qmake lives. Normaly it is located in your Qt5 folder, probably ~/Qt5x.x.x/5.x.x/gcc_64/bin
Open a Linux Terminal
cd to the qtplayground-qtserialport-build folder. Example cd ~/yourqtprojectfolder/pilotnavigator/qtplayground-qtserialport-build
run qmake. Example:
~/Qt5x.x.x/5.x.x/gcc_64/bin/qmake ~/yourqtprojectfolder/pilotnavigator/qtplayground-qtserialport/qtserialport.pro
make
(If you get an error concerning missing file libudev.h, you need to install the libudev-dev library, e.g. sudo apt-get install libudev-dev
)
sudo make install
add a comment |
AFAIK it is based on Qt5+.
I am using Qtserial in my project (pilotnavigator). My QTSDK 5+ is installed locally (not via apt). These are the instructions.
- Copy qtplayground-qtserialport folder into a local folder (preferably where your Qt projects are). Example:
~/yourqtprojectfolder/pilotnavigator/qtplayground-qtserialport
- Create a build folder at the same level called qtplayground-qtserialport-build in pilotnavigator folder. Example:
~/yourqtprojectfolder/pilotnavigator/qtplayground-qtserialport-build
Find out where qmake lives. Normaly it is located in your Qt5 folder, probably ~/Qt5x.x.x/5.x.x/gcc_64/bin
Open a Linux Terminal
cd to the qtplayground-qtserialport-build folder. Example cd ~/yourqtprojectfolder/pilotnavigator/qtplayground-qtserialport-build
run qmake. Example:
~/Qt5x.x.x/5.x.x/gcc_64/bin/qmake ~/yourqtprojectfolder/pilotnavigator/qtplayground-qtserialport/qtserialport.pro
make
(If you get an error concerning missing file libudev.h, you need to install the libudev-dev library, e.g. sudo apt-get install libudev-dev
)
sudo make install
AFAIK it is based on Qt5+.
I am using Qtserial in my project (pilotnavigator). My QTSDK 5+ is installed locally (not via apt). These are the instructions.
- Copy qtplayground-qtserialport folder into a local folder (preferably where your Qt projects are). Example:
~/yourqtprojectfolder/pilotnavigator/qtplayground-qtserialport
- Create a build folder at the same level called qtplayground-qtserialport-build in pilotnavigator folder. Example:
~/yourqtprojectfolder/pilotnavigator/qtplayground-qtserialport-build
Find out where qmake lives. Normaly it is located in your Qt5 folder, probably ~/Qt5x.x.x/5.x.x/gcc_64/bin
Open a Linux Terminal
cd to the qtplayground-qtserialport-build folder. Example cd ~/yourqtprojectfolder/pilotnavigator/qtplayground-qtserialport-build
run qmake. Example:
~/Qt5x.x.x/5.x.x/gcc_64/bin/qmake ~/yourqtprojectfolder/pilotnavigator/qtplayground-qtserialport/qtserialport.pro
make
(If you get an error concerning missing file libudev.h, you need to install the libudev-dev library, e.g. sudo apt-get install libudev-dev
)
sudo make install
edited Jun 10 '13 at 9:44
Eric Carvalho
41.9k17115147
41.9k17115147
answered Jun 10 '13 at 9:21
user166014user166014
362
362
add a comment |
add a comment |
Thanks for contributing an answer to Ask Ubuntu!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f284952%2finstall-qtserialport-library%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown