PDA

View Full Version : How to create QT version for arm-linux-generic-elf-32



shivcena
13th October 2015, 09:29
In my debian linux (with i386 processor).i installed QT creator thats works fine.Also i installed G++ cross compiler to run over another system which is having Debian linux with ARM processor.

Now in QT creator "Tools->Options->Build&Run-->Compilers" i added G++ compiler thats also using "Add" option that also fine.

Now in QT creator "Tools->Options->Build&Run-->Kits" i added new Kit with Name as "G++" , device type as "Desktop" , compiler as "G++ (above step added compiler)" thats also fine.

The problem here is in QT version option.In my QT version option having "QT 5.5.0 GCC 64bit" only. If i select that option it is showing the error because G++ compiler is "arm-linux-generic-elf-32 bit".

It is showing the error like , "The compiler G++ (arm-linux-generic-elf-32 bit) cannot produce code for the QT version QT 5.5.0 GCC 64bit (x86-linux-generic-elf-64bit)"

Guide me how to add QT version for arm-linux-generic-elf-32bit

For me the executable file only enough, no need to run on target directly.

d_stranz
13th October 2015, 16:27
You need to download or build a version of Qt that is compatible with your ARM device and that was built using your cross-compiler. This may be available as a standard Qt binary download. If it is, you are lucky. If it isn't, then you will have to build the parts of Qt you need from the source code, using your cross-compiler.

The Qt download site shows these versions (http://www.qt.io/download-open-source/) for linux and other platforms. I do not know if that is what you need, but you can try it.

I use the Android 32-bit distribution for Windows host, along with the Android NDK toolchains.

shivcena
15th October 2015, 16:09
Thanks for the information, Actually i installed cross compiler "arm-linux-gnueabi-gcc-4.4" in my PC. but i dont have any idea of how to create Qmake file for this compiler. How to create Qmake file for the compiler "arm-linux-gnueabi-gcc-4.4" . without your guidance i cant move a single step forward.Pls guide me,

shivcena
15th October 2015, 16:25
Hi,
Im getting so tired of searching to create Qmake file for compiler. Actually i installed "arm-linux-gnueabi-gcc-4.4" to cross compile. i added the installed compiler in Qt creator "compiler" option also. Now for "kits" option "Device type" , i dont have Qmake file for this compiler supported to add. i dont have any clue for how to make Qmake for this compiler :crying:. If any body knows please guide me to resolve this issue.

d_stranz
15th October 2015, 17:26
I started Qt Creator, switched to the "Welcome" page, changed the drop-down to show "Qt 5.4.1 (android armv7)" (the version I have installed). I then opened the "Analog Clock" example. In the "Projects" page, I selected "Android for armeabi-v7a" and clicked "Configure Project".

The .pro file looks like this:



QT += widgets

HEADERS = analogclock.h
SOURCES = analogclock.cpp \
main.cpp

QMAKE_PROJECT_NAME = widgets_analogclock

# install
target.path = $$[QT_INSTALL_EXAMPLES]/widgets/widgets/analogclock
INSTALLS += target


As you can see, there is nothing in there that identifies ARM as the target platform; that's all in Qt Creator and your kit and project configuration. I can't help you any more than this - the problem seems to be in how you are configuring Qt for your Android kit.

11436

11437

anda_skoa
15th October 2015, 18:51
I am not sure what the problem is.

Where to you build/install Qt for the target platform? That target directory should have a "bin" directory and qmake should be in it.

Cheers,
_

shivcena
16th October 2015, 08:05
i did not installed QT in target platform. To create QT executable for target platform , i installed cross compiler (arm-linux-gnueabi-gcc-4.4) in host system. Then i added the installed cross compiler in QT creator (Tools-->Options-->Build&Run-->Compiler) like below image,
11439

Then i added this compiler in kits option, But in kits option there is option called QT version. In that device type combo box having the Qmake file path , that is not suitable for this installed compiler. So i have to create new Qmake file according to the installed cross compiler (arm-linux-gnueabi-gcc-4.4) , but i have no idea of how to create/configure Qmake file path for this.
Please Refer below image so that you will get the idea in kits option.
11440

anda_skoa
16th October 2015, 09:43
You first need to create the cross compiled build of Qt.
After that you can choose the qmake of that in Qt Creator.

Cheers,
_

d_stranz
17th October 2015, 21:28
As I said in my first answer to your question:


You need to download or build a version of Qt that is compatible with your ARM device and that was built using your cross-compiler. This may be available as a standard Qt binary download.

I downloaded the version I use from the Qt web site, and it works just fine with my Samsung Android tablet.

shivcena
18th October 2015, 10:06
cross compiled build of Qt? can you guide me how to build it? (or) are you have any tutorial link to build it , hope thats help me. For your reference, i installed "arm-linux-gnueabi-gcc-4.4" is a cross compiler i installed in my system. If i found how to make Qmake file for that compiler , then i can build executable for that i hope so,

anda_skoa
18th October 2015, 10:23
http://doc.qt.io/qt-5/embedded-linux.html

Cheers,
_

shivcena
26th October 2015, 07:15
FInally i cross compiled the QT creator application using angstrom cross compiler tool . Then i copied the executable in my board also. Now if i run the executable it is giving the error like "usr/lib/fonts" not found

shivcena
27th October 2015, 14:37
FInally i cross compiled the QT creator application using angstrom cross compiler tool . Then i copied the executable in my board also. Now if i run the executable it is giving the error like "usr/lib/fonts" not found