[Android-development] Building from command line
Matěj Hrazdíra
matejhrazdira at gmail.com
Mon Sep 16 14:23:40 CEST 2013
Hi,
I have some issues with building Android application from command line.
I'm using Qt 5.1.1 and Qt Creator 2.8.1. I can build and run my app from Qt
Creator (deploy on emulator or real device), but I need to be able to build
application from command line / shell script.
When building for desktop, I can build my app with simple script:
#!/bin/bash
# call qmake
~/Qt5.1.1/5.1.1/gcc_64/bin/qmake ~/qtworkspace/helloqt/qttest/untitled/
untitled.pro -r -spec linux-g++
# call make
/usr/bin/make
# run app
./untitled
But for Android, calling qmake and make like this:
#!/bin/bash
# set system environment
export ANDROID_HOME=~/android-sdk-linux
# ... other variables ...
# call qmake
~/Qt5.1.1/5.1.1/android_armv7/bin/qmake
~/qtworkspace/helloqt/qttest/untitled/untitled.pro -r -spec android-g++
# call make
/usr/bin/make INSTALL_ROOT="~/qtworkspace/helloqt/qttest/untitled/android"
install
installs only libuntitled.so to Android libs directory. But when I deploy
my app from Qt Creator, Qt Creator creates a plenty of different libs in
Android libs directory, like gnustl_shared.so, libQt5Core.so, and few
lib--Managed_by_Qt_Creator--plugins_XXX.so.
Next step would be calling ant to build Android apk package, but this is
quite easy.
Does anybody know where to get those libraries, or which command should I
use to create them automatically??? Or where can I get some support? I
spend few days googling, but with no results.
There is no command associated with this operation in Qt Creator project
settings.
Thanks.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/android-development/attachments/20130916/ef48c4ff/attachment.html>
More information about the Android-development
mailing list