Add support for executing project-specific initialization script from the init script

This commit is contained in:
Alex Deryskyba 2014-12-17 05:05:20 +01:00
parent cb503e2a47
commit a918376a7f
2 changed files with 10 additions and 0 deletions

View File

@ -237,6 +237,11 @@ makeinstall_init() {
touch $INSTALL/etc/fstab touch $INSTALL/etc/fstab
ln -sf /proc/self/mounts $INSTALL/etc/mtab ln -sf /proc/self/mounts $INSTALL/etc/mtab
if [ -f $PROJECT_DIR/$PROJECT/initramfs/platform_init ]; then
cp $PROJECT_DIR/$PROJECT/initramfs/platform_init $INSTALL
chmod 755 $INSTALL/platform_init
fi
cp $PKG_DIR/scripts/init $INSTALL cp $PKG_DIR/scripts/init $INSTALL
chmod 755 $INSTALL/init chmod 755 $INSTALL/init
} }

View File

@ -58,6 +58,11 @@
# hide kernel log messages on console # hide kernel log messages on console
echo '1 4 1 7' > /proc/sys/kernel/printk echo '1 4 1 7' > /proc/sys/kernel/printk
# run platform_init script if exists
if [ -f "./platform_init" ]; then
./platform_init
fi
# clear screen and hide cursor # clear screen and hide cursor
clear clear
echo 0 > /sys/devices/virtual/graphics/fbcon/cursor_blink echo 0 > /sys/devices/virtual/graphics/fbcon/cursor_blink