Difference between revisions of "OS: Android - Download"
Onnowpurbo (talk | contribs) |
Onnowpurbo (talk | contribs) |
||
Line 65: | Line 65: | ||
Lakukan | Lakukan | ||
+ | sudo apt-get update | ||
sudo apt-get -q -y install bluez-alsa libgettextpo0 gstreamer0.10-plugins-base \ | sudo apt-get -q -y install bluez-alsa libgettextpo0 gstreamer0.10-plugins-base \ | ||
gstreamer0.10-plugins-good gtk2-engines gtk2-engines-murrine \ | gstreamer0.10-plugins-good gtk2-engines gtk2-engines-murrine \ |
Revision as of 17:36, 12 August 2013
Persiapan
Sumber: http://source.android.com/source/initializing.html
Before you download and build the Android source, ensure your system meets the following requirements:
- A Linux or Mac system. It is also possible to build Android in a virtual machine on unsupported systems such as Windows. If you are running Linux in a virtual machine, you need at least 16GB of RAM/swap and 30GB or more of disk space in order to build the Android tree.
- A 64-bit environment is required for Gingerbread (2.3.x) and newer versions, including the master branch. You can compile older versions on 32-bit systems.
- 30GB of free disk space to complete a single build and up to 100GB or more for a full set of builds. The source download is approximately 8.5GB in size.
- Python 2.6 -- 2.7, which you can download from python.org.
- GNU Make 3.81 -- 3.82, which you can download from gnu.org,
- JDK 6 if you wish to build Gingerbread or newer; JDK 5 for Froyo or older. You can download both from java.sun.com.
- Git 1.7 or newer. You can find it at git-scm.com.
Instalasi sun6 JDK
Sebagai user biasa lakukan
wget --no-cookies --header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F" http://download.oracle.com/otn-pub/java/jdk/6u45-b06/jdk-6u45-linux-x64.bin chmod u+x jdk-6u45-linux-x64.bin ./jdk-6u45-linux-x64.bin sudo mv jdk1.6.0_45 /opt sudo update-alternatives --install "/usr/bin/java" "java" "/opt/jdk1.6.0_45/bin/java" 1 sudo update-alternatives --install "/usr/bin/javac" "javac" "/opt/jdk1.6.0_45/bin/javac" 1 sudo update-alternatives --install "/usr/lib/mozilla/plugins/libjavaplugin.so" "mozilla-javaplugin.so" "/opt/jdk1.6.0_45/jre/lib/amd64/libnpjp2.so" 1 sudo update-alternatives --install "/usr/bin/javaws" "javaws" "/opt/jdk1.6.0_45/bin/javaws" 1
Jika ada lebih dari satu Java, kita dapat set default
sudo update-alternatives --config java sudo update-alternatives --config javac
Atau set JAVA_HOME env variable:
export _JAVA_HOME=/opt/jdk1.6.0_45/
Instalasi Aplikasi Pendukung
sudo apt-get install git gnupg flex bison gperf build-essential \ zip curl libc6-dev libncurses5-dev x11proto-core-dev \ libx11-dev libreadline6-dev libgl1-mesa-glx \ libgl1-mesa-dev g++-multilib mingw32 tofrodos \ python-markdown libxml2-utils xsltproc zlib1g-dev lib32ncurses5 lib32stdc++6
Sumber: projects.kde.org/projects/playground/mobile/necessitas/ministro/repository/revisions/master/raw/Necessitas_SDK/setup_ubuntu_for_necessitas_build.sh
sudo apt-get -q -y install gcc-multilib g++-multilib aptitude p7zip-full \ git-core gitk git-gui git-doc curl gperf zlib1g-dev zlib1g \ flex bison autoconf texinfo build-essential python2.7-dev xorg-dev \ lib32gmp3-dev lib32mpfr-dev lib32ncurses5-dev \ libmpc-dev libgmp3-dev libmpfr-dev libncurses5-dev
# Oracle's Java6; select it when asked. sudo apt-get -q -y install sun-java6-jdk sun-java6-jre sudo update-alternatives --config java
Tambahkan di /etc/apt/sources.list
deb http://ubuntu.mirror.cambrium.nl/ubuntu/ quantal main universe
Lakukan
sudo apt-get update sudo apt-get -q -y install bluez-alsa libgettextpo0 gstreamer0.10-plugins-base \ gstreamer0.10-plugins-good gtk2-engines gtk2-engines-murrine \ gtk2-engines-pixbuf gtk2-engines-oxygen \ gvfs ibus-gtk libacl1 libaio1 libao4 libasound2 \ libasound2-plugins libasyncns0 libattr1 libaudio2 \ libcanberra-gtk-module libcap2 \ bluez-alsa gstreamer0.10-plugins-base gstreamer0.10-plugins-good \ libasound2 libasound2-plugins libcanberra-gtk-module libcupsimage2 libcurl3 libesd0 \ libglapi-mesa libglu1-mesa libqt4-opengl libqtwebkit4 librsvg2-common libsdl-mixer1.2 libsdl-image1.2 \ libsdl-net1.2 libsdl-ttf2.0-0 libsdl1.2debian
Download ia32-libs-multiarch dari
http://sg.archive.ubuntu.com/ubuntu/pool/universe/i/ia32-libs/ia32-libs_20090808ubuntu36_amd64.deb
Install menggunakan
dpkg -i ia32-libs-multiarch_20090808ubuntu36_i386.deb
sudo apt-get -q -y install ia32-libs
Instalasi udev
Edit
vi /etc/udev/rules.d/51-android.rules
Isi dengan
# adb protocol on passion (Nexus One) SUBSYSTEM=="usb", ATTR{idVendor}=="18d1", ATTR{idProduct}=="4e12", MODE="0600", OWNER="<username>" # fastboot protocol on passion (Nexus One) SUBSYSTEM=="usb", ATTR{idVendor}=="0bb4", ATTR{idProduct}=="0fff", MODE="0600", OWNER="<username>" # adb protocol on crespo/crespo4g (Nexus S) SUBSYSTEM=="usb", ATTR{idVendor}=="18d1", ATTR{idProduct}=="4e22", MODE="0600", OWNER="<username>" # fastboot protocol on crespo/crespo4g (Nexus S) SUBSYSTEM=="usb", ATTR{idVendor}=="18d1", ATTR{idProduct}=="4e20", MODE="0600", OWNER="<username>" # adb protocol on stingray/wingray (Xoom) SUBSYSTEM=="usb", ATTR{idVendor}=="22b8", ATTR{idProduct}=="70a9", MODE="0600", OWNER="<username>" # fastboot protocol on stingray/wingray (Xoom) SUBSYSTEM=="usb", ATTR{idVendor}=="18d1", ATTR{idProduct}=="708c", MODE="0600", OWNER="<username>" # adb protocol on maguro/toro (Galaxy Nexus) SUBSYSTEM=="usb", ATTR{idVendor}=="04e8", ATTR{idProduct}=="6860", MODE="0600", OWNER="<username>" # fastboot protocol on maguro/toro (Galaxy Nexus) SUBSYSTEM=="usb", ATTR{idVendor}=="18d1", ATTR{idProduct}=="4e30", MODE="0600", OWNER="<username>" # adb protocol on panda (PandaBoard) SUBSYSTEM=="usb", ATTR{idVendor}=="0451", ATTR{idProduct}=="d101", MODE="0600", OWNER="<username>" # fastboot protocol on panda (PandaBoard) SUBSYSTEM=="usb", ATTR{idVendor}=="0451", ATTR{idProduct}=="d022", MODE="0600", OWNER="<username>" # usbboot protocol on panda (PandaBoard) SUBSYSTEM=="usb", ATTR{idVendor}=="0451", ATTR{idProduct}=="d00f", MODE="0600", OWNER="<username>" # usbboot protocol on panda (PandaBoard ES) SUBSYSTEM=="usb", ATTR{idVendor}=="0451", ATTR{idProduct}=="d010", MODE="0600", OWNER="<username>" # adb protocol on grouper/tilapia (Nexus 7) SUBSYSTEM=="usb", ATTR{idVendor}=="18d1", ATTR{idProduct}=="4e42", MODE="0600", OWNER="<username>" # fastboot protocol on grouper/tilapia (Nexus 7) SUBSYSTEM=="usb", ATTR{idVendor}=="18d1", ATTR{idProduct}=="4e40", MODE="0600", OWNER="<username>" # adb protocol on manta (Nexus 10) SUBSYSTEM=="usb", ATTR{idVendor}=="18d1", ATTR{idProduct}=="4ee2", MODE="0600", OWNER="<username>" # fastboot protocol on manta (Nexus 10) SUBSYSTEM=="usb", ATTR{idVendor}=="18d1", ATTR{idProduct}=="4ee0", MODE="0600", OWNER="<username>"
Download
Sumber: http://source.android.com/source/downloading.html
Inisialisasi Source Code
Sebagai user biasa lakukan
mkdir ~/bin PATH=~/bin:$PATH sudo apt-get install curl curl https://dl-ssl.google.com/dl/googlesource/git-repo/repo > ~/bin/repo chmod a+x ~/bin/repo
Untuk beberapa client sekaligus, sebaiknya kita menggunakan mirror. Asumsinya kita melalukan mirror pada /usr/local/aosp/mirror. Lakukan sebagai user biasa
sudo mkdir -p /usr/local/aosp/mirror sudo mount --bind /media/onno/onnolibrary/repository/android-source/mirror/ /usr/local/aosp/mirror/ sudo chmod -Rf 777 /usr/local/aosp sudo chown -Rf nobody.nogroup /usr/local/aosp cd /usr/local/aosp/mirror repo init -u https://android.googlesource.com/mirror/manifest --mirror repo sync
Di sisi client, dapat melakukan sebagai userbiasa
mkdir -p ~/android-source cd ~/android-source git config --global user.email "you@example.com" git config --global user.name "Your Name" repo init -u /usr/local/aosp/mirror/platform/manifest.git repo sync
Untuk melakukan sync, lakukan secara berurut, dari sisi mirror dan dari sisi master.
$ cd /usr/local/aosp/mirror $ repo sync
$ cd ~/android-source $ repo sync
Tanpa Mirror
Alternatif lain, kalau hanya untuk sendiri tidak perlu melakukan mirror
mkdir -p ~/android-source cd ~/android-source git config --global user.email "you@example.com" git config --global user.name "Your Name" repo init -u https://android.googlesource.com/platform/manifest
Download Source Code
cd ~/android-source repo sync
Referensi
- http://source.android.com/source/initializing.html
- http://source.android.com/source/downloading.html
Pranala Menarik
- Linux
- Ubuntu
- Linux: CLI untuk Survival
- Sistem Operasi
- Linux: Instalasi Sistem Operasi
- Linux: Skema Partisi di Linux
- Kernel
- Compile Kernel
- Compile Kernel: Konfigurasi Kernel
- Kernel: Anatomi Kernel Source
- OS: Linux Kernel
- OS: Parameter Kernel Default
- OS: Kernel Scheduler
- OS: Complete Teori Tuning Kernel Scheduler
- OS: Complete Teori Tuning I/O Performance
- OS: Tuning Manajemen Memory
- OS: Tuning Kernel Scheduler
- OS: Tuning Completely Fair Queueing CFQ I/O scheduler
- OS: Tuning Completely Fair scheduler CFS
- OS: Build in Monitoring Tool
- Linux Benchmarking
- OS: Benchmarking menggunakan UnixBench
- OS: Benchmarking menggunakan LLCBench
- OS: Mengerti System Call
- OS: Membuat Kernel Modul
- OS: Android - Download
- OS: Android - Mirror Source
- OS: Android - Build