Reputation: 565
I am trying to make modifications to few files in android frameworks. What's the fastest approach to compile a new frameworks.jar [mm base/frameworks does not work and make is too slow]
Upvotes: 1
Views: 917
Reputation: 34592
The only way to speed up the compilation of frameworks.jar
is to do the following, which I use this Bash script and invoke this prior to calling . build/envsetup.sh && lunch
on ArchLinux
#!/bin/sh
export USE_CCACHE=1
export CCACHE_DIR=/home/my_user_id/Android_Source/.ccache
/home/my_user_id/Android_Source/prebuilt/linux-x86/ccache/ccache -M 20G
Replace my_user_id
with your linux id, and Android_Source
with the appropriate location where the entire source code reside in.
This allocates a cache of 20Gb, in which common compiled objects are stashed into in order to speed up the build process.
Upvotes: 1