为Android构建QtLocation模块

时间:2013-08-12 12:45:00

标签: android qt build location

现在我正在尝试为Android构建Qt 5.1.2(适用于armeabi libs)

我发现来自git的Qt5源不包括QtLocation和其他一些模块。 所以我试过

git clone git://gitorious.org/qt/qtlocation.git qtlocation 
perl init-repository -f
./configure -android-toolchain-version 4.8 -android-arch armeabi -android-ndk-host linux-x86 -developer-build -xplatform android-g++ -nomake tests -nomake examples -android-ndk /home/onurozcelik/Android/android-ndk-r9/ -android-sdk /home/onurozcelik/Android/android-sdk-linux/ -skip qttools -skip qttranslations -skip qtwebkit -skip qtserialport -skip qtwebkit-examples
make

make后出现以下错误

Entering directory `/home/onurozcelik/qt5/qtlocation/src/3rdparty/poly2tri'
make[3]: Nothing to be done for `first'.
make[3]: Leaving directory `/home/onurozcelik/qt5/qtlocation/src/3rdparty/poly2tri'
make[2]: Leaving directory `/home/onurozcelik/qt5/qtlocation/src/3rdparty'
cd location/ && ( test -e Makefile || /home/onurozcelik/qt5/qtbase/bin/qmake /home/onurozcelik/qt5/qtlocation/src/location/location.pro -o Makefile ) && make -f Makefile 
Project ERROR: Module does not define version.
make[1]: *** [sub-location-make_first-ordered] Error 3
make[1]: Leaving directory `/home/onurozcelik/qt5/qtlocation/src'
make: *** [sub-src-make_first] Error 2

有什么问题?我如何为Android构建QtLocation?

1 个答案:

答案 0 :(得分:1)

克隆并建立Qt位置
git clone git://gitorious.org/qt/qtlocation.git
cd qtlocation
qmake # from qt5
make
make docs
sudo make install