cocoscreator构建的android工程报错
cocoscreator构建的安卓项目打包报错:
Error:The module 'libcocos2dx' is an Android project without build variants, and cannot be built. Please fix the module’s configuration in the build.gradle file and sync the project again.
Error:The module 'xxx' is an Android project without build variants, and cannot be built. Please fix the module’s configuration in the build.gradle file and sync the project again.
我的环境都是ok的,java环境装了,ndk配置了,android sdk也配置了,不知道这个报错什么原因。
网上找了一圈,基本上都是说gradle版本不对,或者没有下载下来,或者是手动添加debug/release configuration。照着网上的方法都试了一遍,依然报错。
最后,博主发现这个是project structure的错误,就在project structure面板里面去找原因,果然发现NDK没有配置。点击下载,完成之后开始自动同步,一切完事之后世界清净了,不报错了。
所以就是NDK的锅,我在cocoscreator里面配置了NDK的,既然无用为什么让我配置。
声明:本站所有文章资源内容,如无特殊说明或标注,均为采集网络资源。如若本站内容侵犯了原著者的合法权益,可联系本站删除。