Qmake library path for arm project
-
I'm using qmake 2.01a and Qt 4.8.4 on a x86 Linux host. I'm having an issue unsetting the default library path when making a bin for an arm target.
qmake adds -L/usr/lib/i386-linux-gnu to the link command even if I override it using LIBS = in the .pro
I also was not able to remove the default qmake -unset QT_INSTALL_LIBS
Below is part of my .pro project file.
LIBS = -L/arm/libs
QMAKE_CC = /arm/gcc-arm-none-eabi/bin/arm-none-eabi-gcc
QMAKE_CXX = /arm/gcc-arm-none-eabi/bin/arm-none-eabi-g++
QMAKE_LINK = /arm/gcc-arm-none-eabi/bin/arm-none-eabi-ld
QMAKE_AR_CMD = /arm/gcc-arm-none-eabi/bin/arm-none-eabi-arQMAKE_CFLAGS_DEBUG += -std=c99
QMAKE_CFLAGS_RELEASE += -std=c99 -
Hi and welcome to devnet,
Are you trying to cross-compile your application using your x86 Qt qmake ?
-
Did you first cross-compile Qt ?
Without that you won't be able to cross-compile your application. Using your x86 qmake won't allow you to build an ARM application, you have to use the one from the ARM Qt
-
Indeed it has, qmake is the first thing built when building Qt.
It's because you are using your system qmake which is configured to use your system build tools.
You would at least need to tell it which mkspec to use (however I can't guarantee that i'll work without a glitch since I have always used qmake from my cross-compiled Qt when working on ARM code)
-
AFAIK it's so because then you don't need to mess around with your system to build a Qt project. But you can modify the paths qmake uses using e.g. qt.conf.
However you didn't answer my question: did you already cross-compile Qt ?
-
Hi and welcome to devnet,
There's already explanations in Qt's documentation. Note that ARM is a processor architecture. Depending on what target board you are using, little things might change.