[출처 : Korea Android]
HOWTO Build Android-X86 Full Source - Ubuntu Users
     ====================================
            Last Modified on 23-Dec-2008 23:10

 
* 인도쪽 개발자분들의 요청으로 세계 공용어인(?)  영문으로 작성하였습니다. 오류 및 오타가 있으면 댓글 바랍니다.

0. My development environments
 - OS : Ubuntu 8.10 Distribution ( 2.6.27-4-generic )
 - CPU:
Intel(R) Core(TM)2 Duo CPU     T5750  @ 2.00GHz ( Samsung SENS R60 Laptop )
 - RAM: Samsung DDR Ram
 - Target: Eee PC (ASUS)
 
1. Query of Linux distribution information
 - At first, Prepare ASUS Eee 701 Lattop or Samsung nettop (NC01).
   And then, confirm system information on your linux distribution like belows.

$ uname -a
Linux invain-laptop 2.6.27-4-generic #1 SMP Wed Sep 24 01:30:51 UTC 2008 i686 GNU/Linux

$ gcc --version
gcc (Ubuntu 4.3.2-1ubuntu10) 4.3.2
Copyright (C) 2008 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.


 
2. repo init and Sync
 - You have to download android full source for x86 architecture like ASUS Eee PC 701.
 - Eee pc dev tree is "git://android.git.kernel.org/platform/vendor/asus/eee_701.git".
$ cd ~
$ mkdir bin_x86 && cd bin_x86
$ mkdir mydroid && cd mydroid
$ repo init -u git://android.git.kernel.org/platform/manifest.git -b cupcake
$ repo sync
$ vi ./.repo/local_manifest.xml 
  <manifest>
    <project name="platform/vendor/asus/eee_701" path="vendor/asus/eee_701"/>
  </manifest>


$ repo sync 
... A new repo command (  1.8) is available.
... You should upgrade soon:

    cp /home/invain/bin_x86/mydroid/.repo/repo/repo /home/invain/bin/repo

Initializing project platform/vendor/asus/eee_701 ...
remote: Counting objects: 33, done.
remote: Compressing objects: 100% (31/31), done.
remote: Total 33 (delta 2), reused 33 (delta 2)
Unpacking objects: 100% (33/33), done.
From git://android.git.kernel.org/platform/vendor/asus/eee_701
 * [new branch]      cupcake    -> korg/cupcake
 * [new branch]      master     -> korg/master

3. Building x86 android full source
$ TARGET_ARCH=x86 TARGET_PRODUCT=eee_701 DISABLE_DEXPREOPT=true make -j2 installer_img

build/core/product_config.mk:207: WARNING: adding test OTA key
============================================
TARGET_PRODUCT=eee_701
TARGET_BUILD_VARIANT=eng
TARGET_SIMULATOR=
TARGET_BUILD_TYPE=release
TARGET_ARCH=x86
HOST_ARCH=x86
HOST_OS=linux
HOST_BUILD_TYPE=release
BUILD_ID=
============================================
build/core/main.mk:178: implicitly installing apns-conf_sdk.xml
                    ............... Below Omission ...................


* Toouble Shooting


$ vi external/srec/tools/thirdparty/OpenFst/fst/lib/../../fst/lib/vector-fst.h
$ vi external/srec/tools/thirdparty/OpenFst/fst/lib/symbol-table.cpp
$ vi frameworks/base/tools/aidl/aidl.cpp --> #include <stdlib.h>,  #include <string.h>
   and so on......


$> ls -lh out/target/product/eee_701/ 
total 770624
drwxrwxr-x  9 invain invain      4096 2008-12-24 16:05 .
drwxrwxr-x  3 invain invain      4096 2008-12-24 15:34 ..
-rw-rw-r--  1 invain invain   2606080 2008-12-24 15:50 boot.img
-rw-rw-r--  1 invain invain        57 2008-12-24 16:03 clean_steps.mk
drwxrwxr-x  4 invain invain      4096 2008-12-24 15:54 data
drwxrwxr-x  2 invain invain      4096 2008-12-24 15:50 grub
drwxrwxr-x  4 invain invain      4096 2008-12-24 16:05 installer
-rw-rw-r--  1 invain invain 406862848 2008-12-24 16:06 installer.img
-rw-rw-r--  1 invain invain   1951340 2008-12-23 19:18 kernel
drwxrwxr-x 12 invain invain      4096 2008-12-24 16:05 obj
-rw-rw-r--  1 invain invain    607384 2008-12-24 15:50 ramdisk.img
drwxrwxr-x  9 invain invain      4096 2008-12-24 15:50 root
drwxrwxr-x  4 invain invain      4096 2008-12-24 15:50 symbols
drwxrwxr-x 12 invain invain      4096 2008-12-24 15:53 system
-rw-rw-r--  1 invain invain 372056064 2008-12-24 16:05 system.img
-rw-rw-r--  1 invain invain   5156864 2008-12-24 16:04 userdata.img


$> file out/target/product/eee_701/installer.img  
./out/target/product/eee_701/installer.img: x86 boot sector; GRand Unified Bootloader, stage1 version 0x3; partition 1: ID=0x83, active, starthead 0, startsector 2048, 8878 sectors; partition 2: ID=0x83, starthead 0, startsector 10926, 783728 sectors


$> file out/target/product/eee_701/installer.img  
  File: `./out/target/product/eee_701/installer.img'
  Size: 406862848     Blocks: 793552     IO Block: 4096   일반 파일
Device: fd00h/64768d    Inode: 5349917     Links: 1
Access: (0664/-rw-rw-r--)  Uid: (  778/  invain)   Gid: (  778/  invain)
Access: 2008-12-24 16:08:21.000000000 +0900
Modify: 2008-12-24 16:06:05.000000000 +0900
Change: 2008-12-24 16:06:05.000000000 +0900


$> file out/target/product/eee_701/system.img  
./out/target/product/eee_701/system.img: Linux rev 0.0 ext2 filesystem data


$> file out/target/product/eee_701/userdata.img
./out/target/product/eee_701/userdata.img: Linux rev 0.0 ext2 filesystem data

$> pushd out/target/product/eee_701/
$> sudo mount -o loop boot.img /mnt
#> popd
total 2519
-rw-rw-r-- 1 invain invain      77 2008-12-24 15:50 cmdline
-rw-rw-r-- 1 invain invain 1951340 2008-12-24 15:50 kernel
-rw-rw-r-- 1 invain invain  607384 2008-12-24 15:50 ramdisk

$> cat /mnt/test/cmndline 
console=tty0 console=ttyS1,115200n8 console=tty0 androidboot.hardware=eee_701
 
$> cp /mnt/test/ramdisk /tmp/ramdisk.gz
$> pushd /tmp
$> gunzip ramdisk.gz
$> cpio -iv < ramdisk
$> popd
init.goldfish.rc
init
data
init.eee_701.rc
proc
sbin
sbin/adbd
system
init.rc
default.prop
lib
lib/modules
lib/modules/atl2.ko
lib/modules/drm.ko
lib/modules/fbcon.ko
lib/modules/cfbimgblt.ko
lib/modules/i915.ko
lib/modules/cfbcopyarea.ko
lib/modules/bitblit.ko
lib/modules/softcursor.ko
lib/modules/font.ko
lib/modules/cfbfillrect.ko
dev
sys
2958 blocks
 
$> file /tmp/init
/tmp/init: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), statically linked, not stripped
 


4. Make USB Stick Installer
$ dd if=out/target/product/eee_701/installer.img of=/dev/<usbstick of your choice>
 
 

 
5.  Now. Enjoy X86 Android Platform!
 
 
본 작업은 아래의 넷북시장에서의 안드로이드의 새로운 출사표를 의미하게 됩니다.
 
 
 

End of Line.
트랙백 주소 :: http://www.mirwing.com/98/trackback/
옵션
댓글 달기