Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. How to setup Qt Creator for android 16kb pages ?
Qt 6.12 LTS is out! See what's new in the release blog

How to setup Qt Creator for android 16kb pages ?

Scheduled Pinned Locked Moved Unsolved Mobile and Embedded
14 Posts 7 Posters 5.9k Views 6 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.
  • A Offline
    A Offline
    Aldebaran
    wrote on last edited by
    #2

    I am in the same situation, i don't have find any statement from Qt;
    My understanding is that we need a version of the qt libs for android compiled in 16KB (i don't know if they will still work on 4KB android system or if we will need to package the two format in the aab (in addition to the differents architectures).

    So two options i think :

    • Rebuild ourself Qt android with 16KB support (don't sound easy);
    • Wait for the 6.9.3 that should support that : https://forum.qt.io/topic/163238/qt-for-android-and-16-kb-page-size-official-roadmap-and-temporary-solutions/3

    I don't know where ekkescorner find this info; but the 6.9.3 should land between the 25 and the 30 of this month : https://wiki.qt.io/Qt_6.9_Release

    So... I will wait a little.

    Pl45m4P 1 Reply Last reply
    0
    • A Aldebaran

      I am in the same situation, i don't have find any statement from Qt;
      My understanding is that we need a version of the qt libs for android compiled in 16KB (i don't know if they will still work on 4KB android system or if we will need to package the two format in the aab (in addition to the differents architectures).

      So two options i think :

      • Rebuild ourself Qt android with 16KB support (don't sound easy);
      • Wait for the 6.9.3 that should support that : https://forum.qt.io/topic/163238/qt-for-android-and-16-kb-page-size-official-roadmap-and-temporary-solutions/3

      I don't know where ekkescorner find this info; but the 6.9.3 should land between the 25 and the 30 of this month : https://wiki.qt.io/Qt_6.9_Release

      So... I will wait a little.

      Pl45m4P Offline
      Pl45m4P Offline
      Pl45m4
      wrote on last edited by
      #3

      @Aldebaran

      I don't know where it's stated officially but the user here indirectly confirmed that this solution apparently works:

      • https://forum.qt.io/topic/162567/solved-update-on-android-15-new-page-size-memory-16kb

      If debugging is the process of removing software bugs, then programming must be the process of putting them in.

      ~E. W. Dijkstra

      1 Reply Last reply
      0
      • ekkescornerE Offline
        ekkescornerE Offline
        ekkescorner
        Qt Champions 2016
        wrote on last edited by
        #4

        see https://bugreports.qt.io/browse/QTBUG-131514
        Fix Version/s: 6.5.10, 6.8.6, 6.9.3, 6.10.0, 6.11.0 FF

        ekke ... Qt Champion 2016 | 2024 ... mobile business apps

        A 1 Reply Last reply
        1
        • ekkescornerE ekkescorner

          see https://bugreports.qt.io/browse/QTBUG-131514
          Fix Version/s: 6.5.10, 6.8.6, 6.9.3, 6.10.0, 6.11.0 FF

          A Offline
          A Offline
          Aldebaran
          wrote on last edited by Aldebaran
          #5

          @ekkescorner Thank you :!
          @Pl45m4 It's not clear to me if the cmake flag is used on a qt android app, a shared native lib, or even on a qt build itself.
          I have tried it without success on my app, at launch android complains that the Qt libs are 4KB aligned.
          My understanding is that only my app has been affected by the flag, and not the qt lib (still in 4KB).

          1 Reply Last reply
          0
          • ekkescornerE Offline
            ekkescornerE Offline
            ekkescorner
            Qt Champions 2016
            wrote on last edited by
            #6

            see also https://www.qt.io/blog/android-15-and-16-support

            ekke ... Qt Champion 2016 | 2024 ... mobile business apps

            M 1 Reply Last reply
            1
            • ekkescornerE ekkescorner

              see also https://www.qt.io/blog/android-15-and-16-support

              M Offline
              M Offline
              MarcoDC
              wrote on last edited by
              #7

              @ekkescorner said in How to setup Qt Creator for android 16kb pages ?:

              see also https://www.qt.io/blog/android-15-and-16-support

              Although this blog post essentially says "upgrade to 6.10.1 when released" xD
              I have run a short script on my mac that checks my included libs

              for f in ./lib/*/*.so; do
                if ! "/Users/<your user>/Library/Android/sdk/ndk/27.2.12479018/toolchains/llvm/prebuilt/darwin-x86_64/bin/llvm-objdump" -p "$f" | grep LOAD | grep -q "align 2\*\*14"; then
                  printf "%s: NEEDS 16KB\n" "$f"
                fi
              done
              

              which outputs:

              ./lib/arm64-v8a/libavcodec.so: NEEDS 16KB
              ./lib/arm64-v8a/libavformat.so: NEEDS 16KB
              ./lib/arm64-v8a/libavutil.so: NEEDS 16KB
              ./lib/arm64-v8a/libcrypto_3.so: NEEDS 16KB
              ./lib/arm64-v8a/libssl_3.so: NEEDS 16KB
              ./lib/arm64-v8a/libswresample.so: NEEDS 16KB
              ./lib/arm64-v8a/libswscale.so: NEEDS 16KB

              for me. I am aware that I have embedded libcrypto and libssl3 manually in my project:

              set_target_properties(${PROJECT_NAME} PROPERTIES
                  ...   
                  # SSL support for TLS backend
                  QT_ANDROID_EXTRA_LIBS "${ANDROID_SDK_ROOT}/android_openssl/ssl_3/${CMAKE_ANDROID_ARCH_ABI}/libcrypto_3.so;${ANDROID_SDK_ROOT}/android_openssl/ssl_3/${CMAKE_ANDROID_ARCH_ABI}/libssl_3.so"
              )
              

              But I don't know why/where libavcodec/libavformat/libavutil and libswresample/libswscale are coming from?
              Does anybody know? Or even better, how to get them to be 16kb aligned too? :D

              1 Reply Last reply
              0
              • SGaistS Offline
                SGaistS Offline
                SGaist
                Lifetime Qt Champion
                wrote on last edited by
                #8

                Hi,

                This thread might be of interest.

                Interested in AI ? www.idiap.ch
                Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                1 Reply Last reply
                0
                • C Offline
                  C Offline
                  Cagnulein
                  wrote on last edited by
                  #9

                  Hi everyone, I don't want to open a new thread for a similar issue, but I will be happy to if needed.

                  I'm try to sovle the 16k issue on my opensource app. I'm building my app with the fresh Qt 6.9.3 and the NDK 28.2.13676358

                  I also added the

                  android {
                  QMAKE_LFLAGS += -Wl,-z,max-page-size=16384 -Wl,-z,common-page-size=16384
                  }

                  in my pro file but when I start the app I got this warning

                  1000002868.png

                  The app is 100% working, so I don't understand what I'm doing wrong. Anyone is facing the same issue?

                  Thanks

                  1 Reply Last reply
                  0
                  • C Offline
                    C Offline
                    Cagnulein
                    wrote on last edited by
                    #10

                    Same thing with the 6.10

                    1 Reply Last reply
                    0
                    • P Offline
                      P Offline
                      philmaubois
                      wrote on last edited by
                      #11

                      Hi all,
                      I have upgraded to 6.9.3 and I removed the 'multimedia' sounds features of my app to validate 16kb aligned, because of ffmpeg uncompatibility.
                      It's ok now. I have still 2 pending issues:

                      • Edge to edge potential problems (google play console feedback) => obsolet API for android.view.Window.getStatusBarColor, android.view.Window.setStatusBarColor, android.view.Window.setNavigationBarColor in org.qtproject.qt.android.QtActivityDelegateBase.handleUiModeChange, org.qtproject.qt.android.QtDisplayManager.setSystemUiVisibility.
                        How to solve that, any idea?
                        Thanks by advance,
                        Philippe
                      ekkescornerE 1 Reply Last reply
                      0
                      • P philmaubois

                        Hi all,
                        I have upgraded to 6.9.3 and I removed the 'multimedia' sounds features of my app to validate 16kb aligned, because of ffmpeg uncompatibility.
                        It's ok now. I have still 2 pending issues:

                        • Edge to edge potential problems (google play console feedback) => obsolet API for android.view.Window.getStatusBarColor, android.view.Window.setStatusBarColor, android.view.Window.setNavigationBarColor in org.qtproject.qt.android.QtActivityDelegateBase.handleUiModeChange, org.qtproject.qt.android.QtDisplayManager.setSystemUiVisibility.
                          How to solve that, any idea?
                          Thanks by advance,
                          Philippe
                        ekkescornerE Offline
                        ekkescornerE Offline
                        ekkescorner
                        Qt Champions 2016
                        wrote on last edited by ekkescorner
                        #12

                        @philmaubois said in How to setup Qt Creator for android 16kb pages ?:

                        Edge to edge potential problems (google play console feedback) => obsolet API

                        please open a bugreport

                        all of my current problems with Qt Safe Areas for edge-to-edge support will be solved with Qt 6.10.1, per ex. https://bugreports.qt.io/browse/QTBUG-139690 or https://bugreports.qt.io/browse/QTBUG-137248
                        also see discussions at https://bugreports.qt.io/browse/QTBUG-135808

                        but I haven't tried with Google Play Console, so probably you run into another issue

                        ekke ... Qt Champion 2016 | 2024 ... mobile business apps

                        1 Reply Last reply
                        0
                        • A Offline
                          A Offline
                          Aldebaran
                          wrote on last edited by
                          #13

                          For me it's launching without problem on a Pixel 8 under Android 16 (with 16k alignment);
                          But, the same app seems to crash at startup on my Pixel 5 (android 14 and 4k alignment), this is something related to the new memory alignment ? If yes, how this will work ? The playstore will required 2 aligned versions to distribute ?
                          I'm a bit lost on this, but it's maybe an error in my own code, will dig in it.

                          And thanks again for everything @ekkescorner; i use your android sharing code, it work as expected under Qt 9.10 (i have had to re-expose myself QtActivity since it is now private but the code remains mostly the same).

                          ekkescornerE 1 Reply Last reply
                          0
                          • A Aldebaran

                            For me it's launching without problem on a Pixel 8 under Android 16 (with 16k alignment);
                            But, the same app seems to crash at startup on my Pixel 5 (android 14 and 4k alignment), this is something related to the new memory alignment ? If yes, how this will work ? The playstore will required 2 aligned versions to distribute ?
                            I'm a bit lost on this, but it's maybe an error in my own code, will dig in it.

                            And thanks again for everything @ekkescorner; i use your android sharing code, it work as expected under Qt 9.10 (i have had to re-expose myself QtActivity since it is now private but the code remains mostly the same).

                            ekkescornerE Offline
                            ekkescornerE Offline
                            ekkescorner
                            Qt Champions 2016
                            wrote on last edited by
                            #14

                            @Aldebaran said in How to setup Qt Creator for android 16kb pages ?:

                            And thanks again for everything @ekkescorner; i use your android sharing code, it work as expected under Qt 9.10 (i have had to re-expose myself QtActivity since it is now private but the code remains mostly the same).

                            thx. good to hear that my old sharing code is working for you. will test it by myself in november/december and publish new example.

                            ekke ... Qt Champion 2016 | 2024 ... mobile business apps

                            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
                            • Unsolved