起步软件技术论坛
搜索
 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 2029|回复: 4

[结贴] 使用第三方插件打包失败

[复制链接]

8

主题

27

帖子

85

积分

初级会员

Rank: 2

积分
85
QQ
发表于 2018-4-9 11:08:54 | 显示全部楼层 |阅读模式

      Running: E:\WeX5_V3.6\model\Native\aw\build\src\platforms\android\gradlew cdvBuildDebug -b E:\WeX5_V3.6\model\Native\aw\build\src\platforms\android\build.gradle -Dorg.gradle.daemon=true
      Incremental java compilation is an incubating feature.
      
      FAILURE: Build failed with an exception.
      
      * What went wrong:
      A problem occurred configuring root project 'android'.
      > Could not resolve all dependencies for configuration ':_debugCompile'.
         > Could not find com.android.support:appcompat-v7:25.3.1.
           Searched in the following locations:
               file:/E:/WeX5_V3.6/tools/maven/repo/com/android/support/appcompat-v7/25.3.1/appcompat-v7-25.3.1.pom
               file:/E:/WeX5_V3.6/tools/maven/repo/com/android/support/appcompat-v7/25.3.1/appcompat-v7-25.3.1.jar
               https://repo1.maven.org/maven2/c ... ompat-v7-25.3.1.pom
               https://repo1.maven.org/maven2/c ... ompat-v7-25.3.1.jar
               file:/E:/WeX5_V3.6/model/Native/aw/build/src/platforms/android/libs/appcompat-v7-25.3.1.jar
               file:/E:/WeX5_V3.6/model/Native/aw/build/src/platforms/android/libs/appcompat-v7.jar
               file:/E:/WeX5_V3.6/tools/adt-sdk/extras/android/m2repository/com/android/support/appcompat-v7/25.3.1/appcompat-v7-25.3.1.pom
               file:/E:/WeX5_V3.6/tools/adt-sdk/extras/android/m2repository/com/android/support/appcompat-v7/25.3.1/appcompat-v7-25.3.1.jar
           Required by:
               :android:unspecified
         > Could not find com.android.support:design:25.3.1.
           Searched in the following locations:
               file:/E:/WeX5_V3.6/tools/maven/repo/com/android/support/design/25.3.1/design-25.3.1.pom
               file:/E:/WeX5_V3.6/tools/maven/repo/com/android/support/design/25.3.1/design-25.3.1.jar
               https://repo1.maven.org/maven2/c ... 1/design-25.3.1.pom
               https://repo1.maven.org/maven2/c ... 1/design-25.3.1.jar
               file:/E:/WeX5_V3.6/model/Native/aw/build/src/platforms/android/libs/design-25.3.1.jar
               file:/E:/WeX5_V3.6/model/Native/aw/build/src/platforms/android/libs/design.jar
               file:/E:/WeX5_V3.6/tools/adt-sdk/extras/android/m2repository/com/android/support/design/25.3.1/design-25.3.1.pom
               file:/E:/WeX5_V3.6/tools/adt-sdk/extras/android/m2repository/com/android/support/design/25.3.1/design-25.3.1.jar
           Required by:
               :android:unspecified
         > Could not find com.android.support:support-v13:25.3.1.
           Searched in the following locations:
               file:/E:/WeX5_V3.6/tools/maven/repo/com/android/support/support-v13/25.3.1/support-v13-25.3.1.pom
               file:/E:/WeX5_V3.6/tools/maven/repo/com/android/support/support-v13/25.3.1/support-v13-25.3.1.jar
               https://repo1.maven.org/maven2/c ... port-v13-25.3.1.pom
               https://repo1.maven.org/maven2/c ... port-v13-25.3.1.jar
               file:/E:/WeX5_V3.6/model/Native/aw/build/src/platforms/android/libs/support-v13-25.3.1.jar
               file:/E:/WeX5_V3.6/model/Native/aw/build/src/platforms/android/libs/support-v13.jar
               file:/E:/WeX5_V3.6/tools/adt-sdk/extras/android/m2repository/com/android/support/support-v13/25.3.1/support-v13-25.3.1.pom
               file:/E:/WeX5_V3.6/tools/adt-sdk/extras/android/m2repository/com/android/support/support-v13/25.3.1/support-v13-25.3.1.jar
           Required by:
               :android:unspecified
         > Could not find com.google.android.gms:play-services-base:9.6.1.
           Searched in the following locations:
               file:/E:/WeX5_V3.6/tools/maven/repo/com/google/android/gms/play-services-base/9.6.1/play-services-base-9.6.1.pom
               file:/E:/WeX5_V3.6/tools/maven/repo/com/google/android/gms/play-services-base/9.6.1/play-services-base-9.6.1.jar
               https://repo1.maven.org/maven2/c ... ices-base-9.6.1.pom
               https://repo1.maven.org/maven2/c ... ices-base-9.6.1.jar
               file:/E:/WeX5_V3.6/model/Native/aw/build/src/platforms/android/libs/play-services-base-9.6.1.jar
               file:/E:/WeX5_V3.6/model/Native/aw/build/src/platforms/android/libs/play-services-base.jar
               file:/E:/WeX5_V3.6/tools/adt-sdk/extras/android/m2repository/com/google/android/gms/play-services-base/9.6.1/play-services-base-9.6.1.pom
               file:/E:/WeX5_V3.6/tools/adt-sdk/extras/android/m2repository/com/google/android/gms/play-services-base/9.6.1/play-services-base-9.6.1.jar
           Required by:
               :android:unspecified
         > Could not find com.android.support:preference-v14:25.3.1.
           Searched in the following locations:
               file:/E:/WeX5_V3.6/tools/maven/repo/com/android/support/preference-v14/25.3.1/preference-v14-25.3.1.pom
               file:/E:/WeX5_V3.6/tools/maven/repo/com/android/support/preference-v14/25.3.1/preference-v14-25.3.1.jar
               https://repo1.maven.org/maven2/c ... ence-v14-25.3.1.pom
               https://repo1.maven.org/maven2/c ... ence-v14-25.3.1.jar
               file:/E:/WeX5_V3.6/model/Native/aw/build/src/platforms/android/libs/preference-v14-25.3.1.jar
               file:/E:/WeX5_V3.6/model/Native/aw/build/src/platforms/android/libs/preference-v14.jar
               file:/E:/WeX5_V3.6/tools/adt-sdk/extras/android/m2repository/com/android/support/preference-v14/25.3.1/preference-v14-25.3.1.pom
               file:/E:/WeX5_V3.6/tools/adt-sdk/extras/android/m2repository/com/android/support/preference-v14/25.3.1/preference-v14-25.3.1.jar
           Required by:
               :android:unspecified
         > Could not find com.android.support:appcompat-v7:25.3.1.
           Searched in the following locations:
               file:/E:/WeX5_V3.6/tools/maven/repo/com/android/support/appcompat-v7/25.3.1/appcompat-v7-25.3.1.pom
               file:/E:/WeX5_V3.6/tools/maven/repo/com/android/support/appcompat-v7/25.3.1/appcompat-v7-25.3.1.jar
               https://repo1.maven.org/maven2/c ... ompat-v7-25.3.1.pom
               https://repo1.maven.org/maven2/c ... ompat-v7-25.3.1.jar
               file:/E:/WeX5_V3.6/model/Native/aw/build/src/platforms/android/libs/appcompat-v7-25.3.1.jar
               file:/E:/WeX5_V3.6/model/Native/aw/build/src/platforms/android/libs/appcompat-v7.jar
               file:/E:/WeX5_V3.6/tools/adt-sdk/extras/android/m2repository/com/android/support/appcompat-v7/25.3.1/appcompat-v7-25.3.1.pom
               file:/E:/WeX5_V3.6/tools/adt-sdk/extras/android/m2repository/com/android/support/appcompat-v7/25.3.1/appcompat-v7-25.3.1.jar
           Required by:
               :android:unspecified > android:CordovaLib:unspecified > android:JustepGetContent:unspecified
      
      * 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: 5.751 secs
      ERROR building one of the platforms: Error: cmd: Command failed with exit code 1
      You may not have the required environment or OS to build this project
      
      E:\WeX5_V3.6\model\Native\aw\build\src\platforms\android\cordova\node_modules\q\q.js:126
                          throw e;
                          ^
      Error code 1 for command: cmd with args: /s /c "E:\WeX5_V3.6\model\Native\aw\build\src\platforms\android\gradlew cdvBuildDebug -b E:\WeX5_V3.6\model\Native\aw\build\src\platforms\android\build.gradle -Dorg.gradle.daemon=true"
      Error: cmd: Command failed with exit code 1
   ****ERROR****: 子任务 "exec" 执行失败。
   ****ERROR****: 任务 "buildAndroid" 执行失败。
   ****ERROR****: 执行出错:
   ****ERROR****: 错误信息: exec returned: 1
   ****ERROR****: 如不能确定具体问题,可参考常见问题: http://bbs.wex5.com/thread-82002-1-1.html
   C:\Users\ADMINI~1\AppData\Local\Temp\7b51dc55-8a00-4ed2-bfc9-b28db96e71bf\pack.xml:88: exec returned: 1
           at org.apache.tools.ant.taskdefs.ExecTask.runExecute(ExecTask.java:643)
           at org.apache.tools.ant.taskdefs.ExecTask.runExec(ExecTask.java:669)
           at org.apache.tools.ant.taskdefs.ExecTask.execute(ExecTask.java:495)
           at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:292)
           at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
           at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
           at java.lang.reflect.Method.invoke(Method.java:497)
           at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
           at org.apache.tools.ant.Task.perform(Task.java:348)
           at org.apache.tools.ant.Target.execute(Target.java:435)
           at org.apache.tools.ant.Target.performTasks(Target.java:456)
           at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1393)
           at org.apache.tools.ant.Project.executeTarget(Project.java:1364)
           at com.justep.deploy.app.utils.BuildHelper.execTask(Unknown Source)
           at com.justep.deploy.app.utils.Builder.main(Unknown Source)


我是使用的v3.6版本打包,是不是和版本有关系?

8

主题

27

帖子

85

积分

初级会员

Rank: 2

积分
85
QQ
 楼主| 发表于 2018-4-9 15:10:08 | 显示全部楼层
生成android应用包:
      Running command: cmd "/s /c "E:\WeX5_V3.7\model\Native\aa\build\src\platforms\android\cordova\build.bat --debug""
      ANDROID_HOME=E:\WeX5_V3.7\tools\adt-sdk
      JAVA_HOME=E:\WeX5_V3.7\java\jre1.8
      Running: E:\WeX5_V3.7\model\Native\aa\build\src\platforms\android\gradlew cdvBuildDebug -b E:\WeX5_V3.7\model\Native\aa\build\src\platforms\android\build.gradle -Dorg.gradle.daemon=true
      NDK is missing a "platforms" directory.
      If you are using NDK, verify the ndk.dir is set to a valid NDK directory.  It is currently set to E:\WeX5_V3.7\tools\adt-sdk\ndk-bundle.
      If you are not using NDK, unset the NDK variable from ANDROID_NDK_HOME or local.properties to remove this warning.
      
      The Task.leftShift(Closure) method has been deprecated and is scheduled to be removed in Gradle 5.0. Please use Task.doLast(Action) instead.
              at build_mjsuekfu1y5ijxdsqaltpymj.run(E:\WeX5_V3.7\model\Native\aa\build\src\platforms\android\build.gradle:155)
      WARNING: The `android.dexOptions.incremental` property is deprecated and it has no effect on the build process.
      NDK is missing a "platforms" directory.
      If you are using NDK, verify the ndk.dir is set to a valid NDK directory.  It is currently set to E:\WeX5_V3.7\tools\adt-sdk\ndk-bundle.
      If you are not using NDK, unset the NDK variable from ANDROID_NDK_HOME or local.properties to remove this warning.
      
      NDK is missing a "platforms" directory.
      If you are using NDK, verify the ndk.dir is set to a valid NDK directory.  It is currently set to E:\WeX5_V3.7\tools\adt-sdk\ndk-bundle.
      If you are not using NDK, unset the NDK variable from ANDROID_NDK_HOME or local.properties to remove this warning.
      
      Incremental java compilation is an incubating feature.
      
      FAILURE: Build failed with an exception.
      
      * What went wrong:
      A problem occurred configuring root project 'android'.
      > You have not accepted the license agreements of the following SDK components:
      [SDK Patch Applier v4, Android Support Repository, Google Repository].
      Before building your project, you need to accept the license agreements and complete the installation of the missing components using the Android Studio SDK Manager.
      Alternatively, to learn how to transfer the license agreements from one workstation to another, go to http://d.android.com/r/studio-ui/export-licenses.html
      
      * Try:
      Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
      Checking the license for package SDK Patch Applier v4 in E:\WeX5_V3.7\tools\adt-sdk\licenses
      Warning: License for package SDK Patch Applier v4 not accepted.
      Checking the license for package Google Repository in E:\WeX5_V3.7\tools\adt-sdk\licenses
      Warning: License for package Google Repository not accepted.
      Checking the license for package Android Support Repository in E:\WeX5_V3.7\tools\adt-sdk\licenses
      Warning: License for package Android Support Repository not accepted.
      
      BUILD FAILED
      
      Total time: 14.563 secs
      ERROR building one of the platforms: Error: cmd: Command failed with exit code 1
      You may not have the required environment or OS to build this project
      
      E:\WeX5_V3.7\model\Native\aa\build\src\platforms\android\cordova\node_modules\q\q.js:126
                          throw e;
                          ^
      Error code 1 for command: cmd with args: /s /c "E:\WeX5_V3.7\model\Native\aa\build\src\platforms\android\gradlew cdvBuildDebug -b E:\WeX5_V3.7\model\Native\aa\build\src\platforms\android\build.gradle -Dorg.gradle.daemon=true"
      Error: cmd: Command failed with exit code 1
   ****ERROR****: 子任务 "exec" 执行失败。
   ****ERROR****: 任务 "buildAndroid" 执行失败。
   ****ERROR****: 执行出错:
   ****ERROR****: 错误信息: exec returned: 1
   ****ERROR****: 如不能确定具体问题,可参考常见问题: http://bbs.wex5.com/thread-82002-1-1.html
   C:\Users\ADMINI~1\AppData\Local\Temp\2337febc-bcae-4cfe-ba6d-89f455039942\pack.xml:91: exec returned: 1
           at org.apache.tools.ant.taskdefs.ExecTask.runExecute(ExecTask.java:643)
           at org.apache.tools.ant.taskdefs.ExecTask.runExec(ExecTask.java:669)
           at org.apache.tools.ant.taskdefs.ExecTask.execute(ExecTask.java:495)
           at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:292)
           at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
           at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
           at java.lang.reflect.Method.invoke(Method.java:497)
           at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
           at org.apache.tools.ant.Task.perform(Task.java:348)
           at org.apache.tools.ant.Target.execute(Target.java:435)
           at org.apache.tools.ant.Target.performTasks(Target.java:456)
           at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1393)
           at org.apache.tools.ant.Project.executeTarget(Project.java:1364)
           at com.justep.deploy.app.utils.BuildHelper.execTask(Unknown Source)
           at com.justep.deploy.app.utils.Builder.main(Unknown Source)
****ERROR****: 子任务 "java" 执行失败。
****ERROR****: 任务 "pack" 执行失败。
****ERROR****: 执行出错:
****ERROR****: 错误信息: Java returned: -3
****ERROR****: 如不能确定具体问题,可参考常见问题: http://bbs.wex5.com/thread-82002-1-1.html


使用3.7版本打包又出现不同的错误,很无助啊。
回复 支持 反对

使用道具 举报

发表于 2018-4-18 14:13:41 | 显示全部楼层
http://docs.wex5.com/wex5-app-question-list-2051
有时候第三方插件并不能完全符合cordova插件标准,就不能打包成功,需要自己研究corodva插件原生开发的知识
qq:1912779713
WeX5教程--WeX5下载
回复 支持 反对

使用道具 举报

8

主题

27

帖子

85

积分

初级会员

Rank: 2

积分
85
QQ
 楼主| 发表于 2018-4-26 10:20:03 | 显示全部楼层
liangyongfei 发表于 2018-4-18 14:13
http://docs.wex5.com/wex5-app-question-list-2051
有时候第三方插件并不能完全符合cordova插件标准,就不 ...

问题已解决,第三方插件打包需要相应的jar文件和aar文件,成功引入后问题就解决了。
回复 支持 反对

使用道具 举报

8

主题

27

帖子

85

积分

初级会员

Rank: 2

积分
85
QQ
 楼主| 发表于 2018-4-26 10:20:22 | 显示全部楼层
Mr.Tree 发表于 2018-4-26 10:20
问题已解决,第三方插件打包需要相应的jar文件和aar文件,成功引入后问题就解决了。 ...

可以结贴了,谢谢
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

小黑屋|手机版|X3技术论坛|Justep Inc.    

GMT+8, 2024-11-22 01:20 , Processed in 0.057312 second(s), 28 queries .

Powered by Discuz! X3.4

© 2001-2013 Comsenz Inc.

快速回复 返回顶部 返回列表