Sunday, September 18, 2016

Establishing Android Build Enviroment under openSuse Leap

Tutorial how set up Android Build Enviroment on openSUSE Leap

If this help's u hit Thanks! :)

1) If you don't have fresh installed openSUSE Leap first you need remove all Java installation, many people might have the wrong version of Java installed.
Code:
sudo zypper remove openjdk-* icedtea-* icedtea6-*
Follow the on-screen instructions to remove any stray Java versions. Otherwise, move on to the next step.

2) Install the main build tools with this command:
Code:
sudo zypper install bison curl flex git gnupg gperf libesd-devel liblz4-1_4 ncurses-devel libSDL-devel python-wxWi dgets-devel libxml2-2 libxml2-tools lzop java-1.7.0-openjdk java-1.7.0-openjdk-devel schedtool squashfs libxslt1 zip zlib-devel make gcc-c++

Appendix to 2:
For 64-bit system also install:
sudo zypper install glibc-devel-32bit ncurses-devel-32bit readline-devel-32bit libz1-32bit

>> build-essential << is Ubuntu meta package which in openSUSE is devel_basis
And u can install it by command
sudo zypper install --type pattern devel_basis
Select y to what it is offering to install.

3) Repo install...
mkdir ~/bin && curl http://commondatastorage.googleapis....downloads/repo > ~/bin/repo && chmod a+x ~/bin/repo

Appendix to 3:
To fix repo sync u will need install this:
sudo zypper install libpth20-32bit
maybe this to:
sudo zypper install openjdk-8-devel

4) Use your favorite text editor to open ~/.bashrc - I like nano:
Code:
nano ~/.bashrc

By default nano is not installed so install it by command:
sudo zypper install nano
5) At the very bottom (use the Page Down key) paste this code to a new line:
Code:
export PATH=~/bin:$PATH
export USE_CCACHE=1

6) Save it. In nano that would be Ctrl-O and then Enter. Then Ctrl-X to exit back to a prompt. Restart bash:
Code:
source ~/.bashrc

7) In the terminal, navigate to where you would like to download the Android source code. The commands below will make it in your home folder.
Code:
mkdir ~/android
cd ~/android

8) Now you're going to initialize the repo. This is where you decide the flavor of Android you want to build, i.e. AOKP, CyanogenMod, AOSP etc.

For the purposes of this tutorial, here's the command for Cyanogenmod 13 (Marshmallow) :
Code:
repo init -u http://ift.tt/1nR8keD -b cm-13.0

9) Time to get the source, many gigabytes of downloading await.
Don't worry, it's automated. It's the last one!
Code:
repo sync
Check back periodically every hour or so. It all depends on how fast your connection is.

That's it! Everything should be ready to go.


from xda-developers http://ift.tt/2cKyktC
via IFTTT

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home