Android source code module compilation and debugging

Source: Internet
Author: User

Android source code of the module compilation debugging

(a) The Source code module modification to compile debugging

1. The first is to pull a complete set of works from Git or SVN, and then make a full compilation, generally this time is relatively long, probably will get 2, 3 hours or so,

2, after the successful compilation, into the source code to modify the module, for example: package/apps/contacts/module, to modify the file to modify

3. Then in the terminal terminal back to the project root directory, android6.0,m code, the original command is to first source, such as: Source xxx.sh xxx_project

4. Then enter the path to the module in the terminal window of this source Mm-b

(b) installed on the mobile phone install method

1. Generated apk, path in/home/xxx1/xxx_project/out/target/product/xxxxxxxx_xx_m0/system/priv-app/contacts/contacts.apk

2 into the ADB, if your Ubuntun installed on the ADB or Windows installed on the ADB, of course, if you use the ADB on Windows, you must first put the APK from Ubuntu on the windows, the method here does not say much, the method is many,

In fact, the installation of JDK, configuration environment variables, Ubuntu and Windows installation method is the same, in fact, the general Android development will install Eclipse or Android studio, and this premise is to install the JDK

(2_1). Now with the ADB example below windows, the Install method

1. Debug the phone with a data cable connected to the computer, let the computer recognize the phone

2.ADB Root

3.ADB Remount (Mount)

4.ADB Intall-r C:\Users\xxx\Desktop\Contacts.apk

(2_2). Now with the ADB example push method under Windows

1.ADB Root

2.ADB remount

3.ADB Push C:\Users\xxx\Desktop\Contacts.apk system/priv-app/contacts/

4.ADB reboot (restart phone)

The 2_2 method is mainly for card-related, such as telephony,telecom and so on

Android source code module compilation and debugging

Related Article

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.