Studio android source into android

The first step is to generate android.ipr

$ source build/envsetup.sh

$ lunch aosp_x86-eng #(or pick your favorite lunch target)

$ make

$ mmm development/tools/idegen/

$ development/tools/idegen/idegen.sh

Step two: find vmoptions files are installed in the path of Android Studio and open: "Android Studio Path" /bin/studio.exe.vmoptions or studio64.exe.vmoptions, modified:

-Xms256m // minimum space 256M
-Xmx1280m // maximum space 1028M

The third step: opening Android Studio, select File-> Open ejection path selection box, enter the appropriate root source, and then select the file android.ipr, it began to import source. During the import process, you need to wait for the index to establish the relevant link, it takes about 10 to 20 minutes. 

Step Four: When we import complete source code, we can see the source code of the whole system of friends, but when we skip class public, and not jump to the corresponding source code under the frameworks directory class, but the jar package class, which is not what we want, we need to let it jump to the appropriate class. We need to create a new library without any jar SDK to rely on the system to the source projects. 
That is not how we want to create a SDK jar of it? Follow these steps: 
Right project name -> Open Module Settings-> Project->  New (JDK)
and select SDKs-> Edit just added jdk-> Delete all packages in the Classpath directory and name 1.6 (No Libraries) 
and then select Modules -> Module SDK select SDK (1.6 (No Libraries)) just edited, and deleted all of the following packages. 
After completion of the above steps, based on the common source system directly to friends. 

 

 

Published 17 original articles · won praise 2 · views 20000 +

Guess you like

Origin blog.csdn.net/toove/article/details/97375652