Mike Lockwood | a2dffa9 | 2010-06-15 20:57:59 -0700 | [diff] [blame] | 1 | on early-init |
| 2 | export EXTERNAL_STORAGE /mnt/sdcard |
| 3 | mkdir /mnt/sdcard 0000 system system |
| 4 | # for backwards compatibility |
| 5 | symlink /mnt/sdcard /sdcard |
| 6 | |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 7 | on boot |
| 8 | setprop ARGH ARGH |
David 'Digit' Turner | eeeca4d | 2011-01-18 20:13:12 +0100 | [diff] [blame] | 9 | setprop net.eth0.gw 10.0.2.2 |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 10 | setprop net.eth0.dns1 10.0.2.3 |
| 11 | setprop net.gprs.local-ip 10.0.2.15 |
| 12 | setprop ro.radio.use-ppp no |
| 13 | setprop ro.build.product generic |
| 14 | setprop ro.product.device generic |
| 15 | |
| 16 | # fake some battery state |
| 17 | setprop status.battery.state Slow |
| 18 | setprop status.battery.level 5 |
| 19 | setprop status.battery.level_raw 50 |
| 20 | setprop status.battery.level_scale 9 |
| 21 | |
| 22 | # disable some daemons the emulator doesn't want |
| 23 | stop dund |
| 24 | stop akmd |
| 25 | |
David 'Digit' Turner | 95df887 | 2011-01-06 11:01:35 +0100 | [diff] [blame] | 26 | # start essential services |
| 27 | start qemud |
| 28 | start goldfish-logcat |
| 29 | start goldfish-setup |
| 30 | |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 31 | setprop ro.setupwizard.mode EMULATOR |
| 32 | |
| 33 | # enable Google-specific location features, |
| 34 | # like NetworkLocationProvider and LocationCollector |
| 35 | setprop ro.com.google.locationfeatures 1 |
| 36 | |
| 37 | # For the emulator, which bypasses Setup Wizard, you can specify |
| 38 | # account info for the device via these two properties. Google |
| 39 | # Login Service will insert these accounts into the database when |
| 40 | # it is created (ie, after a data wipe). |
| 41 | # |
| 42 | # setprop ro.config.hosted_account username@hosteddomain.org:password |
| 43 | # setprop ro.config.google_account username@gmail.com:password |
| 44 | # |
| 45 | # You MUST have a Google account on the device, and you MAY |
| 46 | # additionally have a hosted account. No other configuration is |
| 47 | # supported, and arbitrary breakage may result if you specify |
| 48 | # something else. |
| 49 | |
| 50 | service goldfish-setup /system/etc/init.goldfish.sh |
David 'Digit' Turner | 95df887 | 2011-01-06 11:01:35 +0100 | [diff] [blame] | 51 | user root |
| 52 | group root |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 53 | oneshot |
| 54 | |
David 'Digit' Turner | a503456 | 2011-09-16 00:19:40 +0200 | [diff] [blame] | 55 | # The qemu-props program is used to set various system |
| 56 | # properties on boot. It must be run early during the boot |
| 57 | # process to avoid race conditions with other daemons that |
| 58 | # might read them (e.g. surface flinger), so define it in |
| 59 | # class 'core' |
| 60 | # |
| 61 | service qemu-props /system/bin/qemu-props |
| 62 | class core |
| 63 | user root |
| 64 | group root |
| 65 | oneshot |
| 66 | |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 67 | service qemud /system/bin/qemud |
The Android Open Source Project | f614d64 | 2009-03-18 17:39:49 -0700 | [diff] [blame] | 68 | socket qemud stream 666 |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 69 | oneshot |
| 70 | |
| 71 | # -Q is a special logcat option that forces the |
| 72 | # program to check wether it runs on the emulator |
| 73 | # if it does, it redirects its output to the device |
| 74 | # named by the androidboot.console kernel option |
David 'Digit' Turner | 95df887 | 2011-01-06 11:01:35 +0100 | [diff] [blame] | 75 | # if not, is simply exits immediately |
The Android Open Source Project | dd7bc33 | 2009-03-03 19:32:55 -0800 | [diff] [blame] | 76 | |
| 77 | service goldfish-logcat /system/bin/logcat -Q |
| 78 | oneshot |