diff options
author | Bruce Beare <brucex.j.beare@intel.com> | 2010-04-30 12:48:32 -0700 |
---|---|---|
committer | Bruce Beare <brucex.j.beare@intel.com> | 2010-05-05 09:52:09 -0700 |
commit | f9f1a9d764918cdf5bd6901771e46246a3d2362e (patch) | |
tree | 7a02a1b82c09a014f7c9ad030280316cab6d9aca /target | |
parent | f015e94dc89ea21d40ab06c84e496d01be36ac13 (diff) | |
download | build-f9f1a9d764918cdf5bd6901771e46246a3d2362e.zip build-f9f1a9d764918cdf5bd6901771e46246a3d2362e.tar.gz build-f9f1a9d764918cdf5bd6901771e46246a3d2362e.tar.bz2 |
Add support for x86 VirtualBox Emulation
To make a VirtualBox install image,
make installer_img
Diffstat (limited to 'target')
-rw-r--r-- | target/board/generic_x86/AndroidBoard.mk | 9 | ||||
-rw-r--r-- | target/board/generic_x86/BoardConfig.mk | 12 | ||||
-rw-r--r-- | target/board/generic_x86/README.txt | 15 | ||||
-rw-r--r-- | target/board/generic_x86/disk_layout.conf | 54 |
4 files changed, 79 insertions, 11 deletions
diff --git a/target/board/generic_x86/AndroidBoard.mk b/target/board/generic_x86/AndroidBoard.mk index 9d64d52..ff46149 100644 --- a/target/board/generic_x86/AndroidBoard.mk +++ b/target/board/generic_x86/AndroidBoard.mk @@ -6,3 +6,12 @@ LOCAL_SRC_FILES := init.rc LOCAL_MODULE_CLASS := SHARED_LIBRARIES LOCAL_MODULE_PATH := $(TARGET_ROOT_OUT) include $(BUILD_PREBUILT) + +ifeq ($(TARGET_PREBUILT_KERNEL),) +LOCAL_KERNEL := prebuilt/android-x86/kernel/kernel +else +LOCAL_KERNEL := $(TARGET_PREBUILT_KERNEL) +endif + +PRODUCT_COPY_FILES += \ + $(LOCAL_KERNEL):kernel diff --git a/target/board/generic_x86/BoardConfig.mk b/target/board/generic_x86/BoardConfig.mk index cdc48f3..be8aeb7 100644 --- a/target/board/generic_x86/BoardConfig.mk +++ b/target/board/generic_x86/BoardConfig.mk @@ -9,12 +9,10 @@ USE_CUSTOM_RUNTIME_HEAP_MAX := "32M" TARGET_CPU_ABI := x86 TARGET_USERIMAGES_USE_EXT2 := true TARGET_BOOTIMAGE_USE_EXT2 := true -TARGET_USE_DISKINSTALLER := false - -# For KVM -# BOARD_KERNEL_CMDLINE := console=tty0 console=ttyS1,115200n8 console=tty0 androidboot.hardware=generic_x86 vga=788 - -# For mrst_ref -BOARD_KERNEL_CMDLINE := init=/init pci=noearly console=ttyS0 console=ttyS1,115200n8 console=tty0 earlyprintk=mrst loglevel=8 notsc no_percpu_apbt androidboot.hardware=generic_x86 s0ix_latency=160 +BOARD_KERNEL_CMDLINE := init=/init console=tty0 androidboot.hardware=generic_x86 vga=788 +TARGET_USE_DISKINSTALLER := true +TARGET_DISK_LAYOUT_CONFIG := build/target/board/generic_x86/disk_layout.conf BOARD_BOOTIMAGE_MAX_SIZE := 8388608 +BOARD_SYSLOADER_MAX_SIZE := 7340032 +BOARD_FLASH_BLOCK_SIZE := 512 diff --git a/target/board/generic_x86/README.txt b/target/board/generic_x86/README.txt index 3b88b44..97e2d5b 100644 --- a/target/board/generic_x86/README.txt +++ b/target/board/generic_x86/README.txt @@ -1,6 +1,6 @@ -The generic_x86 board target provides basic services on -very basic hardware. To build with generic_x86, you will -need an appropriate kernel for your device (or emulation). +The generic_x86 board target provides basic services on very basic +hardware (really for an emulation). To build with generic_x86, you will +need an appropriate kernel for your emulation (or device). A1. Create a new top level directory and pull the AOSP repository mkdir $HOME/AOSP @@ -23,4 +23,11 @@ A4. Build make -j8 The build will generate some image files whose format may or may not be correct for your -device. +device. You can build an installer image disk for the VirtualBox emulator using the command: + +A5. Build a VirtualBox installer image + cd $HOME/AOSP + source build/envsetup.sh + lunch generic_x86-eng + make -j8 installer_vdi + diff --git a/target/board/generic_x86/disk_layout.conf b/target/board/generic_x86/disk_layout.conf new file mode 100644 index 0000000..7b073ee --- /dev/null +++ b/target/board/generic_x86/disk_layout.conf @@ -0,0 +1,54 @@ +device { + path /dev/block/sda + + scheme mbr + + # bytes in a disk sector (== 1 LBA), must be a power of 2! + sector_size 512 + + # What LBA should the partitions start at? + start_lba 2048 + + # Autodetect disk size if == 0 + num_lba 0 + + partitions { + sysloader { + active y + type linux + len 7M + } + + recovery { + active y + type linux + len 16M + } + + boot { + active y + type linux + len 8M + } + + cache { + type linux + len 512M + } + + system { + type linux + len 512M + } + + third_party { + type linux + len 512M + } + + data { + type linux + len -1 + } + } +} |