fec2e22f49
* rewrote find_root_partition to make it compatible with the i9100 again (and added a big description comment about how it works) * usb network and dhcp server gets started independent of hooks now. this really makes sense for development now, we can disable this later (and set up networking via OpenRC, when the usb-shell hook is not installed) * telnet splash + unlock telnetd code only runs, when the rootfs is encrypted * usb_setup_android wrapped with a generic usb_setup function, so we can support networking for more device types in a clean way * the IP of the device is now in init_functions.sh, and init_functions.sh gets included in all hooks. * rewrote logging function. it logs all stdout and stderr to /pmOS_init.log, except when PMOS_NO_OUTPUT_REDIRECT is specified as kernel command line. This way we can see error output from all commands. * used shfmt to format everything, so it looks consistent again * added automatic shellchecking for init.sh.in and init_functions.sh * clear naming scheme for initfs functions, they all start with a verb now (e.g. setup_usb_network, start_udhcpd, ...)
35 lines
1.8 KiB
Text
35 lines
1.8 KiB
Text
pkgname=postmarketos-mkinitfs
|
|
pkgver=0.1.0
|
|
pkgrel=1
|
|
pkgdesc="Tool to generate initramfs images for postmarketOS"
|
|
url="https://github.com/postmarketOS"
|
|
# multipath-tools: kpartx
|
|
depends="busybox-extras lddtree cryptsetup kmod multipath-tools"
|
|
triggers="$pkgname.trigger=/etc/postmarketos-mkinitfs/hooks:/usr/share/kernel/*"
|
|
source="init.sh.in init_functions.sh mkinitfs.sh 10-usb-unlock.sh splash1.ppm.gz splash2.ppm.gz"
|
|
arch="noarch"
|
|
license="GPL2"
|
|
provides="mkinitfs=0.0.1"
|
|
|
|
build() {
|
|
return 0
|
|
}
|
|
|
|
package() {
|
|
mkdir -p "$pkgdir/usr/share/postmarketos-mkinitfs/"
|
|
for file in init.sh.in init_functions.sh splash*.ppm.gz; do
|
|
install -Dm644 "$srcdir/$file" \
|
|
"$pkgdir/usr/share/postmarketos-mkinitfs/$file"
|
|
done
|
|
install -Dm755 "$srcdir/mkinitfs.sh" \
|
|
"$pkgdir/sbin/mkinitfs"
|
|
mkdir -p "$pkgdir/etc/postmarketos-mkinitfs/hooks/"
|
|
install -Dm644 "$srcdir/10-usb-unlock.sh" \
|
|
"$pkgdir/etc/postmarketos-mkinitfs/hooks/"
|
|
}
|
|
sha512sums="99d7e3a12ee655b869f6acece453c348cb8f8ed59358331ebed25d4c74186d2afd29c73f62fdc7ff9df352a632dbcb363eae1ef0c988c29acc8f288293ec91d2 init.sh.in
|
|
66f442648fb38529ec594e62ee2307269ca875c7f9340726adcb211e9be42a6ba60fd296af0503a65c7f230c25cf3494783e4282f2468c63116b9500f5d184c6 init_functions.sh
|
|
dd3c86c6ba4f91e20b72f4180049960a58dc01002f69ad9e5d98c752da3b34711c2bbe6e0c7d003eb6a4a8d9e185796aa2fe84c0231a3057b204912c439140f7 mkinitfs.sh
|
|
81d001ab185a8db1b9335d7c8c278d49ab0446bc15bb00dd22e4de16633433a183888f3f1096399bfe361ed719dcc4203afdf4b4f10e74a9c1e50bbbfc46951c 10-usb-unlock.sh
|
|
35a8eabad947347afec7e3f5860d31ab9e3534972c0960ccf553c7e1cc9262316bfdddb8d61d3588db1ee2261077597617806080b9956798b3e5088d6f9b596b splash1.ppm.gz
|
|
bf11d8b3a50db984cfbb2cafe6687de327242c1f6f56c6fdd02ca579b05213f9c886aa1c0527530fdec21b16e65e68962e40a600c4ce155819df2f610b435087 splash2.ppm.gz"
|