Added custom MLL boot logo as default overlay bundle. Fixed issues with missing overlay software sub-folders which were always expected to exist.

This commit is contained in:
Ivan Davidov 2017-12-21 19:40:53 +02:00
parent 66c35aa7f3
commit 6f3e5ba201
7 changed files with 1191 additions and 7 deletions

View File

@ -134,13 +134,14 @@ OVERLAY_TYPE=folder
# felix - Apache Felix OSGi framework. # felix - Apache Felix OSGi framework.
# fio - I/O load generator. # fio - I/O load generator.
# java - Oracle JRE or JDK. Manual preparations are required. # java - Oracle JRE or JDK. Manual preparations are required.
# kbd - keyboard utilities # kbd - keyboard utilities.
# kernel_modules - default MLL kernel modules and 'mdev' hotplug manager. # kernel_modules - default MLL kernel modules and 'mdev' hotplug manager.
# kexec_tools - execute another kernel from userspace # kexec_tools - execute another kernel from userspace
# libevent - event notification library. # libevent - event notification library.
# links - text browser for the web. # links - text browser for the web.
# lua - scripting language. # lua - scripting language.
# make - GNU make utility # make - GNU make utility.
# mll_logo - custom MLL boot logo.
# mll_utils - set of executable utilities (mll-*). # mll_utils - set of executable utilities (mll-*).
# mll_source - MLL source code provided in directory '/usr/src'. # mll_source - MLL source code provided in directory '/usr/src'.
# nano - simple command-line text editor with on-screen shortcuts. # nano - simple command-line text editor with on-screen shortcuts.
@ -166,7 +167,7 @@ OVERLAY_TYPE=folder
# #
# The default overlay bundles are 'dhcp' and 'mll_source'. # The default overlay bundles are 'dhcp' and 'mll_source'.
# #
OVERLAY_BUNDLES=dhcp,mll_source OVERLAY_BUNDLES=dhcp,mll_logo,mll_source
# The location where the overlay bundle software will be stored. # The location where the overlay bundle software will be stored.
# #

View File

@ -56,7 +56,10 @@ set -e
# Read the 'OVERLAY_LOCATION' property from '.config' # Read the 'OVERLAY_LOCATION' property from '.config'
OVERLAY_LOCATION=`read_property OVERLAY_LOCATION` OVERLAY_LOCATION=`read_property OVERLAY_LOCATION`
if [ "$OVERLAY_LOCATION" = "rootfs" -a -d $OVERLAY_ROOTFS ] ; then if [ "$OVERLAY_LOCATION" = "rootfs" \
-a -d $OVERLAY_ROOTFS \
-a ! "`ls -A $OVERLAY_ROOTFS`" = "" ] ; then
echo "Merging overlay software in rootfs." echo "Merging overlay software in rootfs."
# With '--remove-destination' all possibly existing soft links in # With '--remove-destination' all possibly existing soft links in

View File

@ -24,6 +24,7 @@ OVERLAY_LOCATION=`read_property OVERLAY_LOCATION`
if [ "$OVERLAY_LOCATION" = "iso" \ if [ "$OVERLAY_LOCATION" = "iso" \
-a "$OVERLAY_TYPE" = "sparse" \ -a "$OVERLAY_TYPE" = "sparse" \
-a -d $OVERLAY_ROOTFS \ -a -d $OVERLAY_ROOTFS \
-a ! "`ls -A $OVERLAY_ROOTFS`" = "" \
-a "$(id -u)" = "0" ] ; then -a "$(id -u)" = "0" ] ; then
# Use sparse file as storage place. The above check guarantees that the whole # Use sparse file as storage place. The above check guarantees that the whole
@ -74,7 +75,8 @@ if [ "$OVERLAY_LOCATION" = "iso" \
$BUSYBOX losetup -d $LOOP_DEVICE $BUSYBOX losetup -d $LOOP_DEVICE
elif [ "$OVERLAY_LOCATION" = "iso" \ elif [ "$OVERLAY_LOCATION" = "iso" \
-a "$OVERLAY_TYPE" = "folder" \ -a "$OVERLAY_TYPE" = "folder" \
-a -d $OVERLAY_ROOTFS ] ; then -a -d $OVERLAY_ROOTFS \
-a ! "`ls -A $OVERLAY_ROOTFS`" = "" ] ; then
# Use normal folder structure for overlay. All files and folders located in # Use normal folder structure for overlay. All files and folders located in
# the folder 'minimal_overlay' will be merged with the root folder on boot. # the folder 'minimal_overlay' will be merged with the root folder on boot.

View File

@ -21,7 +21,9 @@ else
exit 1 exit 1
fi fi
if [ -d $OVERLAY_ROOTFS ] ; then if [ -d $OVERLAY_ROOTFS \
-a ! "`ls -A $OVERLAY_ROOTFS`" = "" ] ; then
echo "Merging overlay software in image." echo "Merging overlay software in image."
# Copy the overlay content. # Copy the overlay content.

View File

@ -88,10 +88,12 @@ Currently available overlay bundles:
bundle requires GLIBC and ZLIB. bundle requires GLIBC and ZLIB.
Lua - the Lua Scripting Language. Use the 'lua' command to run an Lua - the Lua Scripting Language. Use the 'lua' command to run an
interactive LUA interpreter. interactive Lua interpreter.
make - GNU make utility. make - GNU make utility.
MLL Logo - custom MLL boot logo.
MLL Utils - set of experimental shell scripts (mll-*.sh) which provide MLL Utils - set of experimental shell scripts (mll-*.sh) which provide
additional functionality, e.g. installer and useful tools. additional functionality, e.g. installer and useful tools.
This overlay bundle is currently experimental and its build This overlay bundle is currently experimental and its build

View File

@ -0,0 +1,51 @@
#!/bin/sh
set -e
. ../../common.sh
# Uncomment this to regenerate the MLL logo. The file MLL_LOGO
# has to be existing in advance and it is your responsibility
# to provide it. It is also your responsibility to set your
# development environemnt if some of the commands are missing.
# Maximum allowed logo size is 80x80. Some useful resources:
#
# http://www.armadeus.org/wiki/index.php?title=Linux_Boot_Logo
# http://www.articleworld.org/index.php/How_to_change_the_Linux_penguin_boot_logo
#
#MLL_LOGO=/mnt/hgfs/vm_shared/tux3.ppm
#rm -rf $WORK_DIR/logo
#mkdir -p $WORK_DIR/logo
#cp $MLL_LOGO $WORK_DIR/logo/mll_logo.ppm
#ppmquant 224 $WORK_DIR/logo/mll_logo.ppm > $WORK_DIR/logo/mll_logo_224.ppm
#pnmnoraw $WORK_DIR/logo/mll_logo_224.ppm > $SRC_DIR/mll_logo_ascii_224.ppm
# Read the 'USE_BOOT_LOGO' property from '.config'
USE_BOOT_LOGO=`read_property USE_BOOT_LOGO`
if [ ! "$USE_BOOT_LOGO" = "true" ] ; then
echo "Boot logo has been disabled. No need to generate MLL boot logo."
exit 0
fi
if [ ! -f $WORK_DIR/kernel/linux-*/.config ] ; then
echo "Kernel configuration does not exist. Cannot continue."
exit 1
fi
if [ ! -f $WORK_DIR/kernel/kernel_installed/kernel ] ; then
echo "Kernel image does not exist. Cannot continue."
exit 1
fi
rm -f `ls -d $WORK_DIR/kernel/linux-*`/drivers/video/logo/logo_linux_clut224.ppm
cp $SRC_DIR/mll_logo_ascii_224.ppm `ls -d $WORK_DIR/kernel/linux-*`/drivers/video/logo/logo_linux_clut224.ppm
touch `ls -d $WORK_DIR/kernel/linux-*`/drivers/video/logo/logo_linux_clut224.ppm
cd `ls -d $WORK_DIR/kernel/linux-*`
make bzImage -j 4
cp arch/x86/boot/bzImage $WORK_DIR/kernel/kernel_installed/kernel
cd $SRC_DIR

File diff suppressed because it is too large Load Diff