美文网首页
android添加外部源码到项目

android添加外部源码到项目

作者: 鼾声鼾语 | 来源:发表于2020-05-08 08:57 被阅读0次

1,复制项目包到工程
2,setting.gradle中添加项目名称:include ':app',':cbt'
3,主工程app中添加导入项目 implementation project(':cbt')
4,修改添加项目中的build.gradle的标题apply plugin: 'com.android.library'
5,当前碰到问题:Plugin with id 'com.jfrog.bintray' not found.
这个是单纯环境的问题了,工程的build.gradle中添加
repositories {
google()
jcenter()
maven { url 'https://jitpack.io' }
}
dependencies {
classpath 'com.android.tools.build:gradle:3.1.4'
classpath 'com.github.dcendents:android-maven-gradle-plugin:2.1'
classpath 'org.greenrobot:greendao-gradle-plugin:3.2.1'
classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.8.4'
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}

其中maven需要添加,以及可能用到的classpath。

相关文章

网友评论

      本文标题:android添加外部源码到项目

      本文链接:https://www.haomeiwen.com/subject/ccjxnhtx.html