使用productFlavors 出现错误Configuration with name 'debug' not found.

来源:互联网 发布:天猫淘宝运营招聘信息 编辑:程序博客网 时间:2024/06/10 14:53

在module A里使用productFlavors时:

productFlavors{

testa{

}

testb{

}


编译时出现 Configuration with name 'debug' not found.


原因:其他模块引用了module A,如:

releaseCompile project ( path : 'moduleA" ,configation:'release')

debugCompile project ( path : 'moduleA" ,configation:'debug');

在其他模块找不到moduleA中的release 或者 debug;


解决办法:

其他模块引入的地方 release 修改 为 testaRelease   debug 修改为 testaDebug

releaseCompile project ( path : 'moduleA" ,configation:'release')

debugCompile project ( path : 'moduleA" ,configation:'debug');


阅读全文
0 1
原创粉丝点击