Create a debian chroot as an image file on data partition.
The chroot includes X11 and chromium.
This project is just a starting point, and is not particularly useful as-is
- working: X11 display using framebuffer driver
- not working: touch, buttons, knob, audio, network, basically anything else
This needs to be done from Debian or Ubuntu Linux x86_64, with the multistrap and android-sdk-platform-tools packages installed.
- Before using this, you need to follow the instructions here to setup your device to always boot in usb burning mode.
- After that, power on your device and run
./boot-adb-kernel.shto boot up with adb enabled.- this change is not persistent
- Verify adb is working:
adb devicesshould give you123456 device- It takes a few seconds to become available, be patient
- Run
build.shwhich will:- create
debian-filesystem.imgwith a minimal debian root filesystem, plus some packages as defined inmultistrap.conf. - Will copy
xorg.confinto the image at/etc/X11/xorg.conf.
- create
- Run
deploy.shwhich will:- use adb to push
debian-filesystem.imgto/var/debian-filesystem.imgon the device - copy everything in
scripts/to/scripts/on device. - if you run
./deploy.sh -sit will only push the scripts to the device.
- use adb to push
- Open shell on device:
adb shell - Before activating the chroot, you should probably stop the superbird app:
/etc/init.d/S95supervisord stop- if you want to disable it persistently:
mv /etc/init.d/S95supervisord /etc/init.d/K95supervisord
- if you want to disable it persistently:
- You can activate the chroot (on device) using
/scripts/activate-chroot.sh- will also remount
/as read/write
- will also remount
- Once chroot is activated, try launching chromium:
xinit /usr/bin/chromium --no-sandbox- you need
--no-sandboxbecause running as root
- you need
- Profit?
- To deactivate the chroot, just
exit- will automatically call
/scripts/cleanup-chroot.shto unmount everything - if you ever end up in a situation where the chroot was not cleaned up properly, just run
/scripts/cleanup-chroot.shmanually
- will automatically call
The image file is sized at 1.75GB, leaving about 200MB spare on the data partition. The current list of packages only occupy about 755MB of that, so there is plenty room for more.
The scripts in device-scripts/ will be pushed to the device at /scripts/
activate-chroot.shmount all the things and activate the chrootcleanup-chroot.shclean up all the mounts from the chroot
Some files originate from frederic's repo:
amlogic-usb-toolis justbin/updaterenamed for clarityimages/*are all from that repo. Onlyenv.txthas been modified for readabilityset-bootargs.shis a modified version ofscripts/uart-shell.sh- The only changes I made were to abstract variables, and check OS/arch
- You do not need this unless you have the serial console connected and want to see boot messages there
boot-adb-kernel.shis a modified version ofscripts/upload-kernel.sh- Aside from abstracting some vars, the only real change I made was to remove newline characters from
env.txt; newlines make it easier to read and edit, but they must be stripped before being sent to the device
- Aside from abstracting some vars, the only real change I made was to remove newline characters from
