Android Studio: Are Library Project dependencies picked from project.properties?

独自空忆成欢 提交于 2020-01-11 10:01:29

问题


I have imported my project from ADT and after going to "Module Settings" and editing dependencies things are working fine. My "build.gradle" has dependencies block empty, So I am wondering from where is Ansdroid-Studio picking libraries dependencies ? As I migrated from eclipse so I have project.properties file in module directory. Does Android-studio pick these things from "project.properties" file ?


回答1:


Android Studio's default project support is done through Gradle, unless you have an Android project coming from IntelliJ which you can open with Studio as well.

If you use Gradle, project.properties is completely ignored. You should not use the Module Settings to add dependencies now as it only changes the IDE but not the Gradle based build system (we'll fix this in later versions).

If you have missing dependencies in your build.gradle, it may be due to a bug in the export from ADT. We have fixes for this coming soon.




回答2:


Probably not, since a new project on Android Studio does not generate a project.properties file.

Presumably in Android Studio that is not where dependencies are coming from, but I can't be too sure.



来源:https://stackoverflow.com/questions/16678447/android-studio-are-library-project-dependencies-picked-from-project-properties

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!