Compiling Qt 5.1 Alpha for Android on Ubuntu 12.10 64-bit
I have tried to create a QtCreator project for Android for some days now, using Qt 5.1 Alpha. I have tried to compile Qt with all kinds of parameters, but QtCreator keeps complaining that I have no valid kits available.
I have set up:
- Tools->Options->Android with paths to the android SDK and NDK (64bit linux version).
- Tools->Options->Build&Run->Qt Versions with the /opt/Qt5.1/qtbase/bin/qmake
I get a bunch of compilers "Android GCC (arm-4.7) (android-elf-32bit)" from the NDK.
I get some kits with red exclamation marks saying it cannot find some /opt/ndk/prebuilt/linux-x86/bin/arm... stuff. I don't know why it is looking for x86 version when i downloaded the 64-bit version.
Has anyone been able to create an Android project in QtCreator 2.7 using Ubuntu 12.10 64-bit?
By the way..should Qt be build by root or by user?
This is how I have tried to buid Qt 5.1 (script run with sudo):
apt-get -y install build-essential perl python git "^libxcb.*" libx11-xcb-dev libglu1-mesa-dev libxrender-dev libatspi2.0-dev libdbus-1-dev libicu-dev flex bison gperf libicu-dev libxslt-dev ruby
./configure -developer-build -opensource -xplatform android-g++ -android-ndk /usr/local/lib/android-ndk-r8e -android-sdk /usr/local/lib/android-sdk-linux -nomake tests -nomake examples -no-gtkstyle -confirm-license
I can't answer your main question, but as a rule of thumb you should always build as a non-root user. You may need to run make install as root (if the install location requires that), but never the build itself.
Tried building as normal user to /home/.../lib, but I still get no valid kits. It auto-detects 9 toolchains from the NDK, which are listed under Compilers. However, the auto-detected kits are looking in the prebuilt/linux-x86/bin directory for an arm gdb debugger. The NDK is the 64 bit one from google, which contains prebuilt/linux-x86_64/bin folder, no x86 32-bit folder. How do I get a valid kit for a "Mobile Qt Application"? Is there another project type I am supposed to use?
Which project type should I use for Android/iOS project using Qt5.1 alpha? I have tried both Qt Quick 1 and Qt Quick 2, since “Mobile Qt Application” did not find the available kits useful. However, both Quick types give an error when trying to build:
- Project ERROR: Unknown module(s) in QT: declarative
- Project ERROR: Unknown module(s) in QT: qml quick
In the code editor, it also says QApplication: No such file or directory...
How do I fix this?
Bumping this one up. have a similar issue, with 5.1.0a and 2.7.1.
no suitable kits found, but there are several listed in the options.
@Atlemann: Any success yet?
No success. I tried making a Qt Quick project instead, but then the QtCreator complained that it could not find any of the Q... include files. I'm just going to wait for a beta or final release.
By the way, if I ever get this to work, can make a QtQuick2 project for an app for both Android and iOS or do I have to stick to QtQuick1?
Looks like there's not many people with the relevant knowledge in this forum...
Try posting your question on the mailing list: http://lists.qt-project.org/mailman/listinfo/interest
I'm having the same problem only with the 32-bit version of the newest QT5.1 beta1. Installed ant, java, sdk, ndk after that QT5.1 beta, added android kits in the options (successfully) also added one AVD which starts perfect.
But if I want to create a new QT mobile application for Android it just doesn't show none of the kits that are infact properly installed (no errors anywhere).
Everything else works fine and I have created three seperate qt gui apps without any problems.
Has anyone got any knowledge on this or has the OP found any solutions to this?
Same problem on both win8 and linux gentoo (both 64bit) with Qt 5.1 rc
Same problem here... I have tried everything!
Did you finally succeed?
just use QtQuick2 project, the android version will be removed on the next release