Gradle是否等同于编译器? [英] Is Gradle the Equivalent of a Compiler?

查看:170
本文介绍了Gradle是否等同于编译器?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

据我所知,Gradle是一个构建自动化系统,它结合并描述了应用程序的项目结构,配置和依赖项,以输出APK.这是否意味着Gradle等同于编译器?

From what I know, Gradle is a build automation system that combines and describes the app's project structure, configuration and dependencies to output an APK. Does this mean that the Gradle is equivalent to a compiler?

如果它们不是等效的,那么有什么区别以及它们之间的关系是什么?

If they aren't equivalents, then what are the differences and how do they relate?

推荐答案

Gradle不等同于编译器.编译器主要用于将高级语言(即java)转换为机器代码或其他中间代码表示形式,例如bytecode. wheres Gradle是一个构建系统,可以为您打包代码并使其可以进行编译.如果您以android为例,Gradle将在后台下载定义的依赖项,并为您打包所有内容,而不会弄乱您的情况,并简化了开发流程.它完成了项目的所有依赖关系管理. Gradle输出不是翻译后的代码,相反,您可以说它是安排好的代码.最后,Gradle不等同于任何compiler. 在 StackOverflow帖子上也有类似的问题.与其多次发布,您可以令人满意地接受答案,因此版主可以删除重复的/不被接受的答案.

Gradle is not equivalent to the compiler. Compilers primarily meant for translating the high-level language(i.e. java) into machine code or other intermediate code representation like bytecode. wheres Gradle is a build system that packages the code for you and makes it ready for compilation. If you take an example from android, under the hood, Gradle downloads the defined dependencies and packages everything for you without messing up and simplifies the development flow. It does all the dependencies management for the project. Gradle output is not the translated code, instead, you can say it's arranged code. finally Gradle is not equivalent of any compiler. There is a similar question on StackOverflow Post. Rather putting post multiple times, you can accept satisfactorily answer, so moderators can remove the duplicate/unaccepted one.

这篇关于Gradle是否等同于编译器?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆