其他分享
首页 > 其他分享> > 离子-任务’:processDebugManifest’的执行失败

离子-任务’:processDebugManifest’的执行失败

作者:互联网

当我离子科尔多瓦建立android –release错误来了

ios已经构建成功,但是android无法为我构建,在构建乐趣之前,第一次面对这个问题

最近,我在项目中添加了一些codova插件和第三方登录SDK,现在对我不起作用

zhungzhens-MacBook-Air:minan zhungzhenzhungzhen$ionic cordova build android
Running app-scripts build: --build --iscordovaserve --externalIpRequired --nobrowser

[15:18:50]  build dev started ... 
[15:18:50]  clean started ... 
[15:18:50]  clean finished in 8 ms 
[15:18:50]  copy started ... 
[15:18:50]  transpile started ... 
[15:18:55]  transpile finished in 5.83 s 
[15:18:55]  preprocess started ... 
[15:18:56]  deeplinks started ... 
[15:18:56]  deeplinks finished in 105 ms 
[15:18:56]  preprocess finished in 106 ms 
[15:18:56]  webpack started ... 
[15:18:56]  copy finished in 6.34 s 
[15:19:10]  webpack finished in 14.86 s 
[15:19:10]  sass started ... 
[15:19:12]  sass finished in 1.75 s 
[15:19:12]  postprocess started ... 
[15:19:12]  postprocess finished in 8 ms 
[15:19:12]  lint started ... 
[15:19:12]  build dev finished in 22.64 s 
> cordova build android
⠙ Running command [15:19:22]  lint finished in 10.16 s 
✖ Running command - failed!

[ERROR] Cordova encountered an error.
        You may get more insight by running the Cordova command above directly.

[ERROR] An error occurred while running cordova build android (exit code 1):

        (truncated) ... rscript UP-TO-DATE
        :CordovaLib:compileDebugRenderscript UP-TO-DATE
        :CordovaLib:generateDebugResValues UP-TO-DATE
        :CordovaLib:generateDebugResources UP-TO-DATE
        :CordovaLib:packageDebugResources UP-TO-DATE
        :CordovaLib:processDebugManifest UP-TO-DATE
        :CordovaLib:generateDebugBuildConfig UP-TO-DATE
        :CordovaLib:processDebugResources UP-TO-DATE
        :CordovaLib:generateDebugSources UP-TO-DATE
        :CordovaLib:incrementalDebugJavaCompilationSafeguard UP-TO-DATE
        :CordovaLib:compileDebugJavaWithJavac UP-TO-DATE
        :CordovaLib:processDebugJavaRes UP-TO-DATE
        :CordovaLib:transformResourcesWithMergeJavaResForDebug UP-TO-DATE
        :CordovaLib:transformClassesAndResourcesWithSyncLibJarsForDebug UP-TO-DATE
        :CordovaLib:mergeDebugJniLibFolders UP-TO-DATE
        :CordovaLib:transformNative_libsWithMergeJniLibsForDebug UP-TO-DATE
        :CordovaLib:transformNative_libsWithSyncJniLibsForDebug UP-TO-DATE
        :CordovaLib:bundleDebug UP-TO-DATE
        :CordovaLib:preReleaseBuild UP-TO-DATE
        :CordovaLib:checkReleaseManifest
        :CordovaLib:prepareReleaseDependencies
        :CordovaLib:compileReleaseAidl UP-TO-DATE
        :CordovaLib:compileReleaseNdk UP-TO-DATE
        :CordovaLib:copyReleaseLint UP-TO-DATE
        :CordovaLib:mergeReleaseShaders UP-TO-DATE
        :CordovaLib:compileReleaseShaders UP-TO-DATE
        :CordovaLib:generateReleaseAssets UP-TO-DATE
        :CordovaLib:mergeReleaseAssets UP-TO-DATE
        :CordovaLib:mergeReleaseProguardFiles UP-TO-DATE
        :CordovaLib:packageReleaseRenderscript UP-TO-DATE
        :CordovaLib:compileReleaseRenderscript UP-TO-DATE
        :CordovaLib:generateReleaseResValues UP-TO-DATE
        :CordovaLib:generateReleaseResources UP-TO-DATE
        :CordovaLib:packageReleaseResources UP-TO-DATE
        :CordovaLib:processReleaseManifest UP-TO-DATE
        :CordovaLib:generateReleaseBuildConfig UP-TO-DATE
        :CordovaLib:processReleaseResources UP-TO-DATE
        :CordovaLib:generateReleaseSources UP-TO-DATE
        :CordovaLib:incrementalReleaseJavaCompilationSafeguard UP-TO-DATE
        :CordovaLib:compileReleaseJavaWithJavac UP-TO-DATE
        :CordovaLib:processReleaseJavaRes UP-TO-DATE
        :CordovaLib:transformResourcesWithMergeJavaResForRelease UP-TO-DATE
        :CordovaLib:transformClassesAndResourcesWithSyncLibJarsForRelease UP-TO-DATE
        :CordovaLib:mergeReleaseJniLibFolders UP-TO-DATE
        :CordovaLib:transformNative_libsWithMergeJniLibsForRelease UP-TO-DATE
        :CordovaLib:transformNative_libsWithSyncJniLibsForRelease UP-TO-DATE
        :CordovaLib:bundleRelease UP-TO-DATE
        :prepareComAndroidSupportAnimatedVectorDrawable2531Library UP-TO-DATE
        :prepareComAndroidSupportAppcompatV72531Library UP-TO-DATE
        :prepareComAndroidSupportCardviewV72531Library UP-TO-DATE
        :prepareComAndroidSupportCustomtabs2531Library UP-TO-DATE
        :prepareComAndroidSupportSupportCompat2531Library UP-TO-DATE
        :prepareComAndroidSupportSupportCoreUi2531Library UP-TO-DATE
        :prepareComAndroidSupportSupportCoreUtils2531Library UP-TO-DATE
        :prepareComAndroidSupportSupportFragment2531Library UP-TO-DATE
        :prepareComAndroidSupportSupportMediaCompat2531Library UP-TO-DATE
        :prepareComAndroidSupportSupportV42531Library UP-TO-DATE
        :prepareComAndroidSupportSupportVectorDrawable2531Library UP-TO-DATE
        :prepareComCommit451PhotoView124Library UP-TO-DATE
        :prepareComFacebookAndroidFacebookAndroidSdk4260Library UP-TO-DATE
        :prepareOpenDefault206Library UP-TO-DATE
        :prepareOrgApacheCordovaCordovaLib623DebugLibrary
        :prepareDebugDependencies
        :compileDebugAidl
        :compileDebugRenderscript
        :generateDebugBuildConfig
        :generateDebugResValues
        :generateDebugResources
        :mergeDebugResources
        :processDebugManifest/Users/zhungzhenzhungzhen/Desktop/minan/platforms/android/AndroidManifest.xml:54:9-242
        Error:
        Element activity#com.zhungzhen.minanapp.wxapi.WXEntryActivity at AndroidManifest.xml:54:9-242 duplicated with
        element declared at AndroidManifest.xml:21:9-27:20
        /Users/zhungzhenzhungzhen/Desktop/minan/platforms/android/AndroidManifest.xml Error:
        Validation failed, exiting


        See http://g.co/androidstudio/manifest-merger for more information about the manifest merger.

        :processDebugManifest FAILED

        FAILURE: Build failed with an exception.

        * What went wrong:
        Execution failed for task ':processDebugManifest'.
        > Manifest merger failed with multiple errors, see logs

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

        BUILD FAILED

        Total time: 11.711 secs
        Error: /Users/zhungzhenzhungzhen/desktop/minan/platforms/android/gradlew: Command failed with exit code 1 Error
        output:
        /Users/zhungzhenzhungzhen/Desktop/minan/platforms/android/AndroidManifest.xml:54:9-242 Error:
        Element activity#com.zhungzhen.minanapp.wxapi.WXEntryActivity at AndroidManifest.xml:54:9-242 duplicated with
        element declared at AndroidManifest.xml:21:9-27:20
        /Users/zhungzhenzhungzhen/Desktop/minan/platforms/android/AndroidManifest.xml Error:
        Validation failed, exiting

        FAILURE: Build failed with an exception.

        * What went wrong:
        Execution failed for task ':processDebugManifest'.
        > Manifest merger failed with multiple errors, see logs

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

Two plugins are requesting different versions of the android support
library here.

这是我从互联网上找到的,这是插件问题吗?

这是我的插件列表

com-sarriaroman-photoviewer 1.1.10 "PhotoViewer"
cordova-plugin-console 1.0.5 "Console"
cordova-plugin-device 1.1.4 "Device"
cordova-plugin-facebook4 1.9.1 "Facebook Connect"
cordova-plugin-qqsdk 0.9.6 "QQSDK"
cordova-plugin-sharesdk 0.1.0 "ShareSDK"
cordova-plugin-splashscreen 4.0.3 "Splashscreen"
cordova-plugin-statusbar 2.2.1 "StatusBar"
cordova-plugin-wechat 2.0.0 "Wechat"
cordova-plugin-weibosdk 0.6.0 "WeiboSDK"
cordova-plugin-whitelist 1.3.1 "Whitelist"
cordova-plugin-x-socialsharing 5.1.8 "SocialSharing"
es6-promise-plugin 4.1.0 "Promise"
ionic-plugin-keyboard 2.2.1 "Keyboard"

UPDATE!

最后,我解决了这个问题,并在答案中写下了方式.
enter image description here

解决方法:

通常,此错误是cordova插件问题.

对于我的项目是weibosdk插件问题

我只是删除了weibosdk插件,并在我的项目中发现了一个新的最新插件,然后构建成功.

cordova plugin rm cordova-plugin-weibosdk

因此,当您遇到此问题时,请键入ionic cordova插件列表以列出您在项目中添加的内容,然后检查您的插件过时或存在其他问题.

如果您还有其他建议,请在这篇文章中发表评论.谢谢!

标签:android,ionic2,cordova
来源: https://codeday.me/bug/20191012/1903839.html