android - com.android.ide.common.process.ProcessException : Failed to execute aapt! 我该怎么办?

标签 android ionic-framework build aapt

我尝试在 Android 设备上运行时遇到错误!我不知道发生了什么!

我能做些什么来解决它?

FAILURE:构建失败并出现异常。

构建失败

Total time: 7.791 secs

* What went wrong:
Execution failed for task ':processDebugResources'.
> com.android.ide.common.process.ProcessException: Failed to execute aapt

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
Error: cmd: Command failed with exit code 1 Error output:
C:\tmp\myproj\platforms\android\build\intermediates\res\merged\debug\values\values.xml:373: AAPT: Attribute "theme" already defined with incompatible format.

C:\tmp\myproj\platforms\android\build\intermediates\res\merged\debug\values\values.xml:359: AAPT: Original attribute defined here.

C:\tmp\myproj\platforms\android\build\intermediates\res\merged\debug\values-v26\values-v26.xml:15:21-54: AAPT: No resource found that matches the given name: attr 'android:keyboardNavigationCluster'.

C:\tmp\myproj\platforms\android\build\intermediates\res\merged\debug\values\values.xml:373: error: Attribute "theme" already defined with incompatible format.
C:\tmp\myproj\platforms\android\build\intermediates\res\merged\debug\values\values.xml:359: Original attribute defined here.
C:\tmp\myproj\platforms\android\build\intermediates\res\merged\debug\values-v26\values-v26.xml:15: error: Error: No resource found that matches the given name: attr 'android:keyboardNavigationCluster'.



FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':processDebugResources'.
> com.android.ide.common.process.ProcessException: Failed to execute aapt

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

[ERROR] An error occurred while running cordova run android (exit code 1).

已解决

已解决:重新创建项目并再次添加功能!

最佳答案

只需将此代码放在最后一部分的 build.gradle

configurations.all {
    resolutionStrategy {
        force 'com.android.support:support-v4:27.1.0'
    }
}

关于android - com.android.ide.common.process.ProcessException : Failed to execute aapt! 我该怎么办?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/46133995/

相关文章:

android - 我正在执行系统 ​​("kmsg -v time >/data/temp&");我想要 pid 而不使用 ps 命令

java - 如何从开放位置代码中获取完整代码

javascript - firebase PushID 循环

angular - Ionic 显示等于该值的数据

iphone - 应用程序可以在 iPhone 上运行,但不能在 iPod Touch 上运行

Android googlemaps V2 - 禁用平移或缩放滚动

android - 无法识别的选项 : --illegal-access=permit when running cordova build android

java - 如何在Jenkins中修复 “error: cannot find symbol”?

C++:构建选项 "-j"是什么意思?

android - 您可以将子文件夹添加到 Eclipse Android 项目中的布局吗?