错误:进程以非零退出值1

时间:2018-12-06 02:57:19

标签: android eclipse gradle android-gradle gluon

我目前正在尝试为我的Eclipse Java项目构建一个android apk。

在命令提示符下使用“ gradle-w android”命令时,我一直遇到此错误

Execution failed for task ':PVZApp:processAndroidResourcesDebug'.
> Process 'command 'C:\Program Files (x86)\Android\android-sdk\build- 
tools\28.0.3\aapt.exe'' finished with non-zero exit value 1

以下是我的build.gradle文件的示例:

buildscript {
repositories {
    jcenter()
}
dependencies {
    classpath 'org.javafxports:jfxmobile-plugin:1.3.16'

}
}

apply plugin: 'org.javafxports.jfxmobile'

repositories {
  jcenter()
  maven {
    url 'http://nexus.gluonhq.com/nexus/content/repositories/releases'
}
}

mainClassName = '---------' //Omitted from post

dependencies {
compile 'com.gluonhq:charm:5.0.2'
    compile 'com.android.support:multidex:1.0.0'
}

jfxmobile {
downConfig {
    version = '3.8.6'
    // Do not edit the line below. Use Gluon Mobile Settings in your project context menu instead
    plugins 'display', 'lifecycle', 'statusbar', 'storage'
}
android {
    manifest = 'src/android/AndroidManifest.xml'
    compileSdkVersion = 28;
    buildToolsVersion = '28.0.3'


        dexOptions {
    incremental = true;
    preDexLibraries = false
    javaMaxHeapSize "4g" 
             }
    compileSdkVersion = 28;
    buildToolsVersion = '28.0.3'
}
ios {
    infoPList = file('src/ios/Default-Info.plist')
    forceLinkClasses = [
            'com.gluonhq.**.*',
            'javax.annotations.**.*',
            'javax.inject.**.*',
            'javax.json.**.*',
            'org.glassfish.json.**.*'
    ]
}
}

以下也是我的AndroidManifest.xml文件的示例:

<?xml version="1.0" encoding="UTF-8"?>

-<manifest android:versionName="1.0" android:versionCode="1" 
package="com.gluonapplication" 
xmlns:android="http://schemas.android.com/apk/res-auto">

<supports-screens android:xlargeScreens="true"/>

<uses-permission android:name="android.permission.INTERNET"/>

<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/>

<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>

<uses-sdk android:targetSdkVersion="21" android:minSdkVersion="4"/>


-<application android:name="android.support.multidex.MultiDexApplication" 
android:icon="@mipmap/ic_launcher" android:label="PVZApp">


-<activity android:name="javafxports.android.FXActivity" 
android:label="PVZApp" android:configChanges="orientation|screenSize">

<meta-data android:name="main.class" 
android:value="com.gluonapplication.GluonApplication"/>

<meta-data android:name="debug.port" android:value="0"/>


-<intent-filter>

<action android:name="android.intent.action.MAIN"/>

<category android:name="android.intent.category.LAUNCHER"/>

</intent-filter>

</activity>

<activity android:name="com.gluonhq.impl.charm.down.plugins.android.PermissionRequestActivity"/>

</application>

</manifest>

许多错误似乎都指向AndroidManifest.xml文件,因为命令提示符会显示诸如引用AndroidManifest.xml的错误“包中没有为属性'name'找到资源标识符”

0 个答案:

没有答案