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.sh
to boot up with adb enabled.- this change is not persistent
- Verify adb is working:
adb devices
should give you123456 device
- It takes a few seconds to become available, be patient
- Run
build.sh
which will:- create
debian-filesystem.img
with a minimal debian root filesystem, plus some packages as defined inmultistrap.conf
. - Will copy
xorg.conf
into the image at/etc/X11/xorg.conf
.
- create
- Run
deploy.sh
which will:- use adb to push
debian-filesystem.img
to/var/debian-filesystem.img
on the device - copy everything in
scripts/
to/scripts/
on device. - if you run
./deploy.sh -s
it 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-sandbox
because running as root
- you need
- Profit?
- To deactivate the chroot, just
exit
- will automatically call
/scripts/cleanup-chroot.sh
to unmount everything - if you ever end up in a situation where the chroot was not cleaned up properly, just run
/scripts/cleanup-chroot.sh
manually
- 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.sh
mount all the things and activate the chrootcleanup-chroot.sh
clean up all the mounts from the chroot
Some files originate from frederic's repo:
amlogic-usb-tool
is justbin/update
renamed for clarityimages/*
are all from that repo. Onlyenv.txt
has been modified for readabilityset-bootargs.sh
is 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.sh
is 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