[Android Studio Authoritative tutorial]as build system-gradle

Source: Internet
Author: User

The first few of us talked about the configuration of as, and today we start to get to know the "build system"-gradle of Android Studio.

What is Gradle? Gradle is based on the Groovy language and is oriented toward Java applications. Automated building tools based on DSL (domain-specific language) syntax. "Baidu Encyclopedia"

Include a top-level build file in as and a build file for each module, such as

We'll talk about [top profile and module configuration files and SDK profiles] here.

1. Hierarchy profile

2. Module configuration file

Description
minifyEnable falseis apk to small compression apk meaning: Detailed configuration reference: "Android studio– automatically delete unused resources, give apk minus weight loss"

In the module has been explained as follows, there are generally three kinds of dependencies, add a dependency of the 6 method see here are detailed introduction:
[Android Studio authoritative Tutorial]as 6 ways to add third-party libraries (JAR,MODULE,SO, etc.) "

dependencies {    // Module(模块) 依赖    compile project(":lib")    // 远程二进制依赖    ‘com.android.support:appcompat-v7:19.0.1‘    // 本地二进制依赖    ‘libs‘, include: [‘*.jar‘])}
3.SDK, NDK configuration file

There are mainly two paths configured here: The first one is the SDK, the second is the NDK, and we can configure it in the Project Structrue button:

For the basic understanding of gradle long to here, what multi-channel packaging, NDK configuration and so on we to the late to tell you, to this everyone development what there is no problem, the next article we talk about as signature packaging apk, as well as JKs signature file generation.

Interested children's shoes can follow my blog, my column will continue to update the Android Studio tutorial, as well as I/O assembly on the NDK configuration and compilation, I will also share to everyone.
And I received an invitation from CSND's instructor, and later I will record the use of these Android studio videos into a video published at Csdn College.

/** * -------------- * 欢迎转载   |  转载请注明 * -------------- * 如果对你有帮助,请点击|顶| * -------------- * 请保持谦逊 | 你会走的更远 * -------------- * @author zsl * @github https://github.com/yy1300326388 * @blog http://blog.csdn.net/yy1300326388 */

[Android Studio Authoritative tutorial]as build system-gradle

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.