[Android-development] qt5base - compile error with NDK 8e

Marco Krüger krgsch at gmail.com
Mon Mar 25 17:19:34 CET 2013


Hi guys,

I tried to compile the qt5-base project with the new Android NDK 8e and 
got stuck. BTW, it comiles fine with the NDK 8d!

I'm using the Arch Linux AUR package "android-qt5-qtbase-git", that is 
configured as:

./configure -confirm-license -opensource \
     -developer-build \
     -xplatform android-g++ \
     -android-ndk /opt/android-ndk \
     -android-sdk /opt/android-sdk \
     -prefix /opt/android-qt5 \
     -docdir /usr/share/doc/android-qt5 \
     -nomake docs \
     -nomake examples \
     -nomake tests \
     -no-rpath

-------------------------------------------------------
The compile error:

/opt/android-ndk/toolchains/arm-linux-androideabi-4.7/prebuilt/linux-x86_64/bin/arm-linux-androideabi-g++ 
-c -Wno-psabi -march=armv7-a -mfloat-abi=softfp -mfpu=vfp 
-ffunction-sections -funwind-tables -fstack-protector -fno-short-enums 
-DANDROID -Wa,--noexecstack -std=gnu++0x -g -g -marm -O0 
-fno-omit-frame-pointer -fvisibility=hidden -fvisibility-inlines-hidden 
-Wall -Wno-psabi -W -D_REENTRANT -fPIC -DQT_NO_PRINTDIALOG 
-DQT_NO_LIBUDEV -DQT_NO_XCB -DQT_NO_XKBCOMMON -DQT_NO_USING_NAMESPACE 
-DQT_BUILD_CORE_LIB -DQT_BUILDING_QT -DQT_NO_CAST_TO_ASCII 
-DQT_ASCII_CAST_WARNINGS -DQT_MOC_COMPAT -DQT_USE_QSTRINGBUILDER 
-DQT_DEPRECATED_WARNINGS -DQT_DISABLE_DEPRECATED_BEFORE=0x050000 
-DPCRE_HAVE_CONFIG_H -DQT_CORE_LIB -I../../mkspecs/android-g++ -I. 
-I../../include -I../../include/QtCore -I../../include/QtCore/5.1.0 
-I../../include/QtCore/5.1.0/QtCore -Iglobal -I../3rdparty/pcre 
-I../3rdparty/harfbuzz/src -I../3rdparty/md5 -I../3rdparty/md4 
-I../3rdparty/sha3 -I.moc/debug-shared 
-I/opt/android-ndk/sources/cxx-stl/gnu-libstdc++/4.7/include 
-I/opt/android-ndk/sources/cxx-stl/gnu-libstdc++/4.7/libs/armeabi-v7a/include 
-I/opt/android-ndk/platforms/android-9/arch-arm/usr/include -o 
.obj/debug-shared/

qwaitcondition_unix.o thread/qwaitcondition_unix.cpp
thread/qwaitcondition_unix.cpp: In function 'void 
qt_initialize_pthread_cond(pthread_cond_t*, const char*)':
thread/qwaitcondition_unix.cpp:75:61: error: 'pthread_condattr_setclock' 
was not declared in this scope

make[2]: *** [.obj/debug-shared/qwaitcondition_unix.o] Fehler 1
make[2]: Leaving directory 
`/home/noisy/android-qt5-qtbase-git/src/qt5-qtbase/src/corelib'
make[1]: *** [sub-corelib-make_first] Fehler 2
make[1]: Leaving directory 
`/home/noisy/android-qt5-qtbase-git/src/qt5-qtbase/src'
make: *** [sub-src-make_first] Fehler 2

-------------------------------------------------------
Another not related question - Does the "OpenGL ES 2.0 Cube" example 
work for your on Android devices out of the box? I get only a black 
window and a warning message:
"QAndroidPlatformIntegration::createPlatformWindow: Unsupported case: 
More than one top-level window created."

Thanks!

Marco



More information about the Android-development mailing list