Compiling Android ICS on Linux Mint 17

These are some issues I faced compiling Android on Linux Mint 17:
Error:
frameworks/base/include/utils/KeyedVector.h:193:31: error: ‘indexOfKey’ was not declared in this scope, and no declarations were found by argument-dependent lookup at the point of instantiation [-fpermissive]
ssize_t i = indexOfKey(key);

Fix:
vi frameworks/base/tools/aapt/Android.mk

Add ‘-fpermissive’ to line 31:
LOCAL_CFLAGS += -Wno-format-y2k -fpermissive

Error:
external/srec/tools/thirdparty/OpenFst/fst/lib/cache.h:136:11: note: use ‘this->SetState’ instead
make: *** [out/host/linux-x86/obj/EXECUTABLES/grxmlcompile_intermediates/grxmlcompile.o] Error 1

Fix:
cd external/srec
wget “https://github.com/CyanogenMod/android_external_srec/commit/4d7ae7b79eda47e489669fbbe1f91ec501d42fb2.diff”
patch -p1 < 4d7ae7b79eda47e489669fbbe1f91ec501d42fb2.diff
rm -f 4d7ae7b79eda47e489669fbbe1f91ec501d42fb2.diff
cd ../..

Source: http://blog.csdn.net/yiyaaixuexi/article/details/8330645

Also I installed these programs:

sudo apt-get install multistrap
sudo apt-get install u-boot-tools
sudo apt-get install xsltproc
sudo apt-get install libxml2-utils
sudo apt-get install openjdk-6-jdk
sudo apt-get install libc6-dev-i386
sudo apt-get install gcc-multilib
sudo apt-get install libstdc++-4.8-dev
sudo apt-get install lib32stdc++-4.8-dev
sudo apt-get install zlib1g-dev
sudo apt-get install lib32z1-dev
sudo apt-get install libncurses5-dev
sudo apt-get install libncurses-dev
sudo apt-get install libx32ncurses5-dev

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s