2023-10-20 01:16:43 +00:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
console=$1
|
|
|
|
subpkgname=${subpkgname:-ERROR}
|
|
|
|
|
|
|
|
if [ "$subpkgname" = "ERROR" ]; then
|
|
|
|
echo "ERROR: devicepkg_pmtest_post_install should only be called" >&2
|
|
|
|
echo "from an APKBUILD subpackage function" >&2
|
|
|
|
fi
|
|
|
|
|
|
|
|
# Install a trigger so that mkinitfs will run when this package is installed
|
|
|
|
# shellcheck disable=SC2154
|
|
|
|
mkdir -p "$subpkgdir/usr/share/mkinitfs-triggers/"
|
|
|
|
touch "$subpkgdir/usr/share/mkinitfs-triggers/$subpkgname"
|
|
|
|
|
|
|
|
# Echo out the .post-install data for the calling package to pipe to their
|
|
|
|
# .post-install file
|
|
|
|
cat <<EOF
|
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
echo -e "\n# PMOS CI: enable console logging" >> /etc/deviceinfo
|
2024-06-18 19:53:59 +00:00
|
|
|
echo 'deviceinfo_kernel_cmdline_append="console=$console"' >> /etc/deviceinfo
|
2023-10-20 01:16:43 +00:00
|
|
|
EOF
|