Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. QT 5.3 error compiling for Android
Forum Updated to NodeBB v4.3 + New Features

QT 5.3 error compiling for Android

Scheduled Pinned Locked Moved Mobile and Embedded
2 Posts 2 Posters 1.5k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    dan82
    wrote on last edited by
    #1

    Hi for all.

    I try compile QT 5.3 with Android support.
    Ubunty 13.10 64bit
    Install Android SDK (ver 19) + install ver 11

    $JAVA_HOME=/usr/lib/jvm/java-7-openjdk-amd64
    $ANDROID_API_VERSION=19

    ./configure -developer-build -opensource -confirm-license -xplatform android-g++ -no-gtkstyle -nomake tests -nomake examples -android-ndk /data/install/QT/SDK/android-ndk-r9d -android-sdk /data/install/QT/SDK/android-sdk-linux -android-ndk-host linux-x86_64 -android-toolchain-version 4.8 -skip qttranslations -skip qtwebkit -skip qtserialport -skip qtwebkit-examples -no-warnings-are-errors -static -no-dbus

    After make see this error:

    /data/install/QT/SDK/android-ndk-r9d/toolchains/arm-linux-androideabi-4.8/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 -gdwarf-2 -marm -O0 -fno-omit-frame-pointer -fno-exceptions -Wall -Wno-psabi -W -D_REENTRANT -fPIE -DQT_NO_MTDEV -DQT_NO_LIBUDEV -DQT_NO_EXCEPTIONS -DQT_POSITIONING_LIB -DQT_CORE_LIB -I/data/install/QT53/qt5/qtbase/mkspecs/android-g++ -I. -I/data/install/QT53/qt5/qtbase/include -I/data/install/QT53/qt5/qtbase/include/QtPositioning -I/data/install/QT53/qt5/qtbase/include/QtCore -I.moc -I/data/install/QT/SDK/android-ndk-r9d/sources/cxx-stl/gnu-libstdc++/4.8/include -I/data/install/QT/SDK/android-ndk-r9d/sources/cxx-stl/gnu-libstdc++/4.8/libs/armeabi-v7a/include -isystem /data/install/QT/SDK/android-ndk-r9d/platforms/android-9/arch-arm/usr/include -o .obj/libpositioning_cppsnippet.so_plugin_import.o libpositioning_cppsnippet.so_plugin_import.cpp
    /data/install/QT/SDK/android-ndk-r9d/toolchains/arm-linux-androideabi-4.8/prebuilt/linux-x86_64/bin/arm-linux-androideabi-g++ --sysroot=/data/install/QT/SDK/android-ndk-r9d/platforms/android-9/arch-arm/ -Wl,-soname,libpositioning_cppsnippet.so -Wl,--no-undefined -Wl,-z,noexecstack -shared -o libpositioning_cppsnippet.so .obj/main.o .obj/cppqml.o .obj/libpositioning_cppsnippet.so_plugin_import.o -L/data/install/QT/SDK/android-ndk-r9d/sources/cxx-stl/gnu-libstdc++/4.8/libs/armeabi-v7a -L/data/install/QT/SDK/android-ndk-r9d/platforms/android-9/arch-arm//usr/lib -L/data/install/QT53/qt5/qtbase/lib -L/data/install/QT53/qt5/qtbase/plugins/position -lqtposition_android -lqtposition_positionpoll -lQt5Positioning -lQt5Core -lgnustl_shared -llog -lz -lm -ldl -lc -lgcc -lgnustl_shared -llog -lz -lm -ldl -lc -lgcc
    libpositioning_cppsnippet.so_plugin_import.cpp:4: error: undefined reference to 'qt_static_plugin_AndroidPositionPlugin()'
    libpositioning_cppsnippet.so_plugin_import.cpp:5: error: undefined reference to 'qt_static_plugin_PollPositionPlugin()'
    collect2: error: ld returned 1 exit status
    make[4]: *** [libpositioning_cppsnippet.so] Error 1
    make[4]: Leaving directory /data/install/QT53/qt5/qtlocation/src/positioning/doc/snippets/cpp' make[3]: *** [sub-cpp-make_first] Error 2 make[3]: Leaving directory /data/install/QT53/qt5/qtlocation/src/positioning/doc/snippets'
    make[2]: *** [sub-positioning-doc-snippets-make_first] Error 2
    make[2]: Leaving directory /data/install/QT53/qt5/qtlocation/src' make[1]: *** [sub-src-make_first] Error 2 make[1]: Leaving directory /data/install/QT53/qt5/qtlocation'
    make: *** [module-qtlocation-make_first] Error 2

    Goolge have't answer how i can fix this error.
    Pls help :)

    1 Reply Last reply
    0
    • S Offline
      S Offline
      Sidii
      wrote on last edited by
      #2

      Dear Dan82

      bq. libpositioning_cppsnippet.so_plugin_import.cpp:4: error: undefined reference to ‘qt_static_plugin_AndroidPositionPlugin()’
      libpositioning_cppsnippet.so_plugin_import.cpp:5: error: undefined reference to ‘qt_static_plugin_PollPositionPlugin()’
      collect2: error: ld returned 1 exit status

      It seems some Android library is missing that is why you are getting undefined reference error.

      1 Reply Last reply
      0

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved