在Ubuntu上编译Android Gingerbread 2.3.1
- MorrisC - 易水博客前几天下载了Android 2.3.1的源代码并在Ubuntu 10.04(32位)上编译通过. 这篇文章简要记录了下载、编译的过程. 关于搭建Android开发环境的文章已经有很多,本文只简要介绍一下,做为备忘. 这一步安装获取源代码以及编译所需要的软件,使用如下命令:. 另外,参考别人编译Android 2.3的经验,安装了下列软件包:.
emulator -verbose 可以查看运行过程。
luo@luo-station:~/android-4.0.3$ emulator -verbose emulator: found Android build root: /home/luo/android-4.0.3 emulator: found Android build out: /home/luo/android-4.0.3/out/target/product/generic emulator: Found target ABI=armeabi-v7a, architecture=arm emulator: Found target API level: 15 emulator: using core hw config path: /home/luo/android-4.0.3/out/target/product/generic/hardware-qemu.ini emulator: found skin-specific hardware.ini: /home/luo/android-4.0.3/development/tools/emulator/skins/HVGA/hardware.ini emulator: autoconfig: -skin HVGA emulator: autoconfig: -skindir /home/luo/android-4.0.3/development/tools/emulator/skins emulator: writing default keyset file to /home/luo/.android/default.keyset emulator: trying to load skin file '/home/luo/android-4.0.3/development/tools/emulator/skins/HVGA/layout' emulator: skin network speed: 'full' emulator: skin network delay: 'none' emulator: Found target ABI=armeabi-v7a emulator: autoconfig: -kernel /home/luo/android-4.0.3/prebuilt/android-arm/kernel/kernel-qemu-armv7 emulator: autoconfig: -ramdisk /home/luo/android-4.0.3/out/target/product/generic/ramdisk.img emulator: autoconfig: -sysdir /home/luo/android-4.0.3/out/target/product/generic emulator: Using initial system image: /home/luo/android-4.0.3/out/target/product/generic/system.img emulator: WARNING: system partition size adjusted to match image file (166 MB > 66 MB) emulator: autoconfig: -data /home/luo/android-4.0.3/out/target/product/generic/userdata-qemu.img emulator: autoconfig: -initdata /home/luo/android-4.0.3/out/target/product/generic/userdata.img emulator: Physical RAM size: 512MB emulator: Auto-config: -qemu -cpu cortex-a8 Content of hardware configuration file: hw.cpu.arch = arm hw.cpu.model = cortex-a8 hw.ramSize = 512 hw.touchScreen = yes hw.mainKeys = yes hw.trackBall = yes hw.keyboard = yes hw.keyboard.lid = no hw.keyboard.charmap = qwerty2 hw.dPad = yes hw.gsmModem = yes hw.camera = no hw.camera.maxHorizontalPixels = 640 hw.camera.maxVerticalPixels = 480 hw.gps = yes hw.battery = yes hw.accelerometer = yes hw.audioInput = yes hw.audioOutput = yes hw.sdCard = yes hw.sdCard.path = disk.cachePartition = yes disk.cachePartition.path = disk.cachePartition.size = 66m hw.lcd.width = 320 hw.lcd.height = 480 hw.lcd.depth = 16 hw.lcd.density = 160 hw.lcd.backlight = yes hw.gpu.enabled = no hw.fakeCamera = back hw.webcam.count = 6 hw.webcam.0.name = webcam0 hw.webcam.1.name = webcam1 hw.webcam.2.name = webcam2 hw.webcam.3.name = webcam3 hw.webcam.4.name = webcam4 hw.webcam.5.name = webcam5 hw.webcam.0.direction = front hw.webcam.1.direction = back hw.webcam.2.direction = front hw.webcam.3.direction = front hw.webcam.4.direction = front hw.webcam.5.direction = front vm.heapSize = 48 hw.sensors.proximity = yes kernel.path = /home/luo/android-4.0.3/prebuilt/android-arm/kernel/kernel-qemu-armv7 kernel.parameters = android.checkjni=1 disk.ramdisk.path = /home/luo/android-4.0.3/out/target/product/generic/ramdisk.img disk.systemPartition.initPath = /home/luo/android-4.0.3/out/target/product/generic/system.img disk.systemPartition.size = 166m disk.dataPartition.path = /home/luo/android-4.0.3/out/target/product/generic/userdata-qemu.img disk.dataPartition.size = 66m disk.snapStorage.path = avd.name = <build> . QEMU options list: emulator: argv[00] = "/home/luo/android-4.0.3/out/host/linux-x86/bin/emulator-arm" emulator: argv[01] = "-android-hw" emulator: argv[02] = "/tmp/android-luo/emulator-afcKDX" Concatenated QEMU options: /home/luo/android-4.0.3/out/host/linux-x86/bin/emulator-arm -android-hw /tmp/android-luo/emulator-afcKDX emulator: registered 'boot-properties' qemud service emulator: nand_add_dev: system,size=0xa600000,initfile=/home/luo/android-4.0.3/out/target/product/generic/system.img emulator: mapping 'system' NAND image to /tmp/android-luo/emulator-eyG1eN emulator: rounding devsize up to a full eraseunit, now a608000 WARNING: Data partition already in use. Changes will not persist! emulator: nand_add_dev: userdata,size=0x4200000 emulator: mapping 'userdata' NAND image to /tmp/android-luo/emulator-RO2LHH emulator: registered 'boot-properties' qemud service emulator: Adding boot property: 'dalvik.vm.heapsize' = '48m' emulator: Adding boot property: 'qemu.sf.lcd_density' = '160' emulator: Adding boot property: 'qemu.hw.mainkeys' = '1' emulator: Adding boot property: 'qemu.sf.fake_camera' = 'back' emulator: nand_add_dev: cache,size=0x4200000 emulator: mapping 'cache' NAND image to /tmp/android-luo/emulator-wX6JvG emulator: Kernel parameters: qemu.gles=0 qemu=1 console=ttyS0 android.qemud=ttyS1 android.checkjni=1 ndns=1 emulator: Trace file name is not set emulator: autoconfig: -scale 1 emulator: control console listening on port 5556, ADB on port 5557 emulator: can't connect to ADB server: Connection refused emulator: ping program: /home/luo/android-4.0.3/out/host/linux-x86/bin/ddms emulator: ping command: /home/luo/android-4.0.3/out/host/linux-x86/bin/ddms ping emulator 14.0 goldfish_fb_get_pixel_format:167: display surface,pixel format: bits/pixel: 16 bytes/pixel: 2 depth: 16 red: bits=5 mask=0xf800 shift=11 max=0x1f green: bits=6 mask=0x7e0 shift=5 max=0x3f blue: bits=5 mask=0x1f shift=0 max=0x1f alpha: bits=0 mask=0x0 shift=0 max=0x0