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. [Android] Issues with ant
QtWS25 Last Chance

[Android] Issues with ant

Scheduled Pinned Locked Moved Mobile and Embedded
13 Posts 3 Posters 6.7k Views
  • 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.
  • F Offline
    F Offline
    Flamaros
    wrote on last edited by
    #1

    I have some issues I don't understand with ant during the clean debug command.
    Here is the trace :
    @17:20:38: Déploiement du paquet : exécution de la commande "C:/sdk/apache-ant-1.9.1/bin/ant.bat clean debug".
    Buildfile: C:\projects\HomeDesign3D\Projects\Qt\android\build.xml

    -check-env:
    [checkenv] Android SDK Tools Revision 22.0.1
    [checkenv] Installed at C:\sdk\adt-bundle-windows-x86_64-20130522\sdk

    -setup:
    [echo] Project Name: Home Design 3D
    [gettype] Project Type: Application

    ....

     [echo] ----------
     [echo] Handling Resources...
     [aapt] Generating resource IDs...
     [aapt] C:\projects\HomeDesign3D\Projects\Qt\android\bin\AndroidManifest.xml:9: error: Error: No resource found that matches the given name (at 'resource' with value '@array/qt_sources').
     [aapt] C:\projects\HomeDesign3D\Projects\Qt\android\bin\AndroidManifest.xml:10: error: Error: No resource found that matches the given name (at 'value' with value '@string/repository').
     [aapt] C:\projects\HomeDesign3D\Projects\Qt\android\bin\AndroidManifest.xml:11: error: Error: No resource found that matches the given name (at 'resource' with value '@array/qt_libs').
     [aapt] C:\projects\HomeDesign3D\Projects\Qt\android\bin\AndroidManifest.xml:12: error: Error: No resource found that matches the given name (at 'resource' with value '@array/bundled_libs').
     [aapt] C:\projects\HomeDesign3D\Projects\Qt\android\bin\AndroidManifest.xml:16: error: Error: No resource found that matches the given name (at 'resource' with value '@array/bundled_in_lib').
     [aapt] C:\projects\HomeDesign3D\Projects\Qt\android\bin\AndroidManifest.xml:17: error: Error: No resource found that matches the given name (at 'resource' with value '@array/bundled_in_assets').
    

    BUILD FAILED
    C:\sdk\adt-bundle-windows-x86_64-20130522\sdk\tools\ant\build.xml:650: The following error occurred while executing this line:
    C:\sdk\adt-bundle-windows-x86_64-20130522\sdk\tools\ant\build.xml:691: null returned: 1

    Total time: 1 second
    Erreur de paquetage : la commande "C:/sdk/apache-ant-1.9.1/bin/ant.bat clean debug" a échoué.Code de sortie : 1
    Erreur lors de la compilation/déploiement du projet HomeDesign3D (kit : Android for arm (GCC 4.7, Qt 5.1.0))
    Lors de l'exécution de l'étape "Paquetage pour Android"@

    My manifest :
    @<?xml version='1.0' encoding='utf-8'?>
    <manifest android:versionCode="1" package="fr.anuman.HomeDesign3D" xmlns:android="http://schemas.android.com/apk/res/android" android:versionName="300">
    <application android:name="org.qtproject.qt5.android.bindings.SingletonQtApplication" android:label="@string/app_name">
    <activity android:name="org.qtproject.qt5.android.bindings.QtActivity" android:configChanges="orientation|locale|fontScale|keyboard|keyboardHidden|navigation" android:label="@string/app_name">
    <intent-filter>
    <action android:name="android.intent.action.MAIN"/>
    <category android:name="android.intent.category.LAUNCHER"/>
    </intent-filter>
    <meta-data android:name="android.app.qt_sources_resource_id" android:resource="@array/qt_sources"/>
    <meta-data android:name="android.app.repository" android:value="@string/repository"/>
    <meta-data android:name="android.app.qt_libs_resource_id" android:resource="@array/qt_libs"/>
    <meta-data android:name="android.app.bundled_libs_resource_id" android:resource="@array/bundled_libs"/>
    <meta-data android:name="android.app.lib_name" android:value="HomeDesign3D"/>
    <!-- Deploy Qt libs as part of package -->
    <meta-data android:name="android.app.bundle_local_qt_libs" android:value="1"/>
    <meta-data android:name="android.app.bundled_in_lib_resource_id" android:resource="@array/bundled_in_lib"/>
    <meta-data android:name="android.app.bundled_in_assets_resource_id" android:resource="@array/bundled_in_assets"/>
    <!-- Run with local libs -->
    <meta-data android:name="android.app.use_local_qt_libs" android:value="1"/>
    <meta-data android:name="android.app.libs_prefix" android:value="/data/local/tmp/qt/"/>
    <meta-data android:name="android.app.load_local_libs" android:value=":"/>
    <meta-data android:name="android.app.load_local_jars" android:value=":"/>
    <meta-data android:name="android.app.static_init_classes" android:value=":"/>
    <!-- Messages maps -->
    <meta-data android:name="android.app.ministro_not_found_msg" android:value="@string/ministro_not_found_msg"/>
    <meta-data android:name="android.app.ministro_needed_msg" android:value="@string/ministro_needed_msg"/>
    <meta-data android:name="android.app.fatal_error_msg" android:value="@string/fatal_error_msg"/>
    <!-- Messages maps -->
    <!-- Splash screen -->
    <meta-data android:name="android.app.splash_screen" android:resource="@layout/splash"/>
    <!-- Splash screen -->
    </activity>
    </application>
    <supports-screens android:largeScreens="true" android:normalScreens="true" android:anyDensity="true" android:smallScreens="true"/>
    <uses-permission android:name="android.permission.INTERNET"/>
    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
    </manifest>@

    My device target support android SDK 10.

    1 Reply Last reply
    0
    • M Offline
      M Offline
      Moster
      wrote on last edited by
      #2

      Show your android configuration in the Qt creator.

      1 Reply Last reply
      0
      • F Offline
        F Offline
        Flamaros
        wrote on last edited by
        #3

        Which part of my android configuration can be wrong? Because I had already tested a lot of think.

        My android sdk and ndk seems correctly configured, and it's the same for ant and jdk paths.

        1 Reply Last reply
        0
        • M Offline
          M Offline
          Moster
          wrote on last edited by
          #4

          Could you pls show a screenshot of it?
          Btw, make sure you have the x86 ndk, but this most likely wont cause this issue

          1 Reply Last reply
          0
          • F Offline
            F Offline
            Flamaros
            wrote on last edited by
            #5

            "Screenshot":https://docs.google.com/file/d/0BygGiQfhIcvGN21qaFYwQmNNaFk/edit?usp=sharing

            I have the x86_64 ndk because I under Windows Seven 64bits.
            Please notice, I already get it works with this ndk.

            1 Reply Last reply
            0
            • M Offline
              M Offline
              Moster
              wrote on last edited by
              #6

              But Qt is not made for x64 actually, at least not the windows version.
              Btw, update your java jdk. Its outdated and vulnerable.
              What might be an issue is that you are using x86 JDK, but not the x86 NDK.

              Edit: I just checked my windows install of Qt (usually I use linux) and I have the x86 NDK and x64 java.
              http://i.imgur.com/P7iQraG.png
              On linux I also got this clean debug error, but it was related to some false java directory, so it wasnt working.

              1 Reply Last reply
              0
              • F Offline
                F Offline
                Flamaros
                wrote on last edited by
                #7

                Ok nothing works.
                I put sdk and ndk in 32bits, upgrade jdk and test ant 1.8.4 version. Every-thing without success.
                I also launched qmake and restarted my computer.

                1 Reply Last reply
                0
                • M Offline
                  M Offline
                  Moster
                  wrote on last edited by
                  #8

                  Hmm, somewhere I read this might happen if you have any kind of special character in one of the resources (like a library name, app name etc.)
                  Btw, regarding the resource errors you get. Could you pls go to your Qt project, then /android/res/values and show the content of libs.xml

                  1 Reply Last reply
                  0
                  • A Offline
                    A Offline
                    AcerExtensa
                    wrote on last edited by
                    #9

                    [quote author="Moster" date="1376038382"]
                    On linux I also got this clean debug error, but it was related to some false java directory, so it wasnt working.[/quote]

                    Simply install java sdk in separate folder, select this folder in QtCreator settings and it will work... have had same problem.

                    After any changes do not forgot to delete "android" folder in your project folder. Run qmake and build your project, android folder will be recreated with current settings.

                    God is Real unless explicitly declared as Integer.

                    1 Reply Last reply
                    0
                    • M Offline
                      M Offline
                      Moster
                      wrote on last edited by
                      #10

                      [quote author="AcerExtensa" date="1376048185"]
                      [quote author="Moster" date="1376038382"]
                      On linux I also got this clean debug error, but it was related to some false java directory, so it wasnt working.[/quote]

                      Simply install java sdk in separate folder, select this folder in QtCreator settings and it will work... have had same problem.

                      After any changes do not forgot to delete "android" folder in your project folder. Run qmake and build your project, android folder will be recreated with current settings.
                      [/quote]

                      Thanks, but I resolved this error ages ago :) I just said that it was related to a wrong java sdk folder in my android configuration

                      1 Reply Last reply
                      0
                      • A Offline
                        A Offline
                        AcerExtensa
                        wrote on last edited by
                        #11

                        Oh, ok, but for Flamaros try this:

                        bq. After any changes do not forgot to delete “android” folder in your project folder. Run qmake and build your project, android folder will be recreated with current settings.

                        God is Real unless explicitly declared as Integer.

                        1 Reply Last reply
                        0
                        • F Offline
                          F Offline
                          Flamaros
                          wrote on last edited by
                          #12

                          Thanks a lot, It works.

                          We have some issues with the android folder, because we added some java files and do some modifications modifications in the androidManifest to launch our own java Application object.

                          [quote author="AcerExtensa" date="1376048822"]Oh, ok, but for Flamaros try this:

                          bq. After any changes do not forgot to delete “android” folder in your project folder. Run qmake and build your project, android folder will be recreated with current settings. [/quote]

                          1 Reply Last reply
                          0
                          • F Offline
                            F Offline
                            Flamaros
                            wrote on last edited by
                            #13

                            I just found that I can use Context.getApplicationContext() instead of inherit QtApplication, to be able to call java methods I need for our extentions

                            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