Skip to content

Commit 6a3e383

Browse files
committed
Keep trying to fix readme
1 parent 629876c commit 6a3e383

File tree

1 file changed

+10
-5
lines changed

1 file changed

+10
-5
lines changed

README.md

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,25 +8,27 @@ This branch of the device configs is intended to give you a more modern emmc typ
88

99
To boot this in the emulator, build your recoveryimage. With the Android emulator make a new device based on a Galaxy Nexus. Allow it to have a hardware keyboard and a sdcard. Give it a name like TWRP. Then from your android-sdk/tools folder run the following command:
1010

11+
```
1112
./emulator -avd TWRP -ramdisk ~/cm_folder/out/target/product/twrp/ramdisk-recovery.img -kernel ~/cm_folder/device/emulator/twrp/goldfish_2.6_kernel
13+
```
1214

1315
After the first boot, wait for ADB to start up, then: adb shell /sbin/create_partitions.sh
1416

1517
This script will partition the sdcard with a boot, recovery, system, cache, data, and removable sdcard partition. It's designed to work with a 1500MiB sdcard. If you want a different sdcard size then you will need to modify the script in the cm_folder/device/emulator/twrp/recovery/root/sbin/create_partitions.sh location to suit your needs. The script will also copy the existing system files from the MTD system partition to the new emmc-based partition.
1618

1719
If you want to make the emulator boot up using the emmc partitions, you will need to modify the ramdisk.img. Locate the ramdisk.img in your android-sdk/system-images/android##/armeabi-v7a/ folder. To unpack it:
1820

21+
```
1922
mkdir ramdisk
20-
2123
cd ramdisk
22-
2324
gzip -dc ../ramdisk.img | cpio -i
25+
```
2426

2527
Modify the init.rc to mount your mmc based partitions instead of the mtd ones by locating the line in init.rc that says "on fs" and modifying it to look like this:
2628

27-
# Changes for init.rc
28-
on fs
29-
# mount emmc partitions
29+
```
30+
on fs
31+
# mount emmc partitions
3032
# Mount /system rw first to give the filesystem a chance to save a checkpoint
3133
# mount yaffs2 mtd@system /system
3234
# mount yaffs2 mtd@system /system ro remount
@@ -35,10 +37,13 @@ Modify the init.rc to mount your mmc based partitions instead of the mtd ones by
3537
mount ext4 /dev/block/mmcblk0p3 /system wait ro
3638
mount ext4 /dev/block/mmcblk0p5 /data wait noatime nosuid nodev
3739
mount ext4 /dev/block/mmcblk0p4 /cache wait noatime nosuid nodev
40+
```
3841

3942
Save the changes and repack the ramdisk image as follows:
4043

44+
```
4145
find . | cpio -o -H newc > gzip > ../newramdisk.img
46+
```
4247

4348
Boot the emulator using -ramdisk path/to/newramdisk.img -kernel path/to/goldfish_2.6_kernel
4449

0 commit comments

Comments
 (0)