mirror of
https://github.com/LibreELEC/LibreELEC.tv.git
synced 2025-07-28 13:16:41 +00:00
Merge pull request #3783 from stefansaraev/mkimage
mkimage enhancements
This commit is contained in:
commit
36a10d2003
@ -147,3 +147,6 @@
|
|||||||
|
|
||||||
# build and install 'FishBMC' Visualization (yes / no)
|
# build and install 'FishBMC' Visualization (yes / no)
|
||||||
KODI_VIS_FISHBMC="no"
|
KODI_VIS_FISHBMC="no"
|
||||||
|
|
||||||
|
# kernel image name
|
||||||
|
KERNEL_NAME="kernel.img"
|
||||||
|
@ -160,3 +160,6 @@
|
|||||||
# extra build dependeices
|
# extra build dependeices
|
||||||
EXTRA_DEPS="mkimage"
|
EXTRA_DEPS="mkimage"
|
||||||
EXTRA_DEPS_PKG="u-boot-tools"
|
EXTRA_DEPS_PKG="u-boot-tools"
|
||||||
|
|
||||||
|
# kernel image name
|
||||||
|
KERNEL_NAME="kernel.img"
|
||||||
|
@ -296,16 +296,21 @@ IMAGE_NAME="$DISTRONAME-$TARGET_VERSION"
|
|||||||
if [ "$2" == "efi" ] ; then
|
if [ "$2" == "efi" ] ; then
|
||||||
UEFI=yes
|
UEFI=yes
|
||||||
fi
|
fi
|
||||||
|
# projects can set KERNEL_NAME (kernel.img)
|
||||||
|
if [ -z "$KERNEL_NAME" ] ; then
|
||||||
|
KERNEL_NAME="KERNEL"
|
||||||
|
fi
|
||||||
echo "mkimage: boo. now root access (sudo) is required..."
|
echo "mkimage: boo. now root access (sudo) is required..."
|
||||||
echo "mkimage: see scripts/image and scripts/mkimage if you dont trust us :)"
|
echo "mkimage: see scripts/image and scripts/mkimage if you dont trust us :)"
|
||||||
# variables used in image script must be passed
|
# variables used in image script must be passed
|
||||||
sudo env \
|
sudo env \
|
||||||
PATH="$PATH" \
|
PATH="$PATH:/sbin" \
|
||||||
ROOT="$ROOT" \
|
ROOT="$ROOT" \
|
||||||
TOOLCHAIN="$TOOLCHAIN" \
|
TOOLCHAIN="$TOOLCHAIN" \
|
||||||
TARGET_IMG="$TARGET_IMG" \
|
TARGET_IMG="$TARGET_IMG" \
|
||||||
IMAGE_NAME="$IMAGE_NAME" \
|
IMAGE_NAME="$IMAGE_NAME" \
|
||||||
BOOTLOADER="$BOOTLOADER" \
|
BOOTLOADER="$BOOTLOADER" \
|
||||||
|
KERNEL_NAME="$KERNEL_NAME" \
|
||||||
RELEASE_DIR="$RELEASE_DIR" \
|
RELEASE_DIR="$RELEASE_DIR" \
|
||||||
UUID_SYSTEM="$(uuidgen)" \
|
UUID_SYSTEM="$(uuidgen)" \
|
||||||
UUID_STORAGE="$(uuidgen)" \
|
UUID_STORAGE="$(uuidgen)" \
|
||||||
|
@ -171,12 +171,12 @@ MENU COLOR tabmsg 31;40 #ff868787 #00000000 std
|
|||||||
|
|
||||||
LABEL installer
|
LABEL installer
|
||||||
MENU LABEL Run $DISTRONAME Installer
|
MENU LABEL Run $DISTRONAME Installer
|
||||||
KERNEL /KERNEL
|
KERNEL /$KERNEL_NAME
|
||||||
APPEND boot=UUID=$UUID_SYSTEM installer quiet tty vga=current
|
APPEND boot=UUID=$UUID_SYSTEM installer quiet tty vga=current
|
||||||
|
|
||||||
LABEL live
|
LABEL live
|
||||||
MENU LABEL Run $DISTRONAME Live
|
MENU LABEL Run $DISTRONAME Live
|
||||||
KERNEL /KERNEL
|
KERNEL /$KERNEL_NAME
|
||||||
APPEND boot=UUID=$UUID_SYSTEM disk=UUID=$UUID_STORAGE quiet vga=current
|
APPEND boot=UUID=$UUID_SYSTEM disk=UUID=$UUID_STORAGE quiet vga=current
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
@ -190,7 +190,7 @@ EOF
|
|||||||
|
|
||||||
# copy files
|
# copy files
|
||||||
echo "image: copying files to part1..."
|
echo "image: copying files to part1..."
|
||||||
cp $TARGET_IMG/$IMAGE_NAME.kernel "$OE_TMP/KERNEL"
|
cp $TARGET_IMG/$IMAGE_NAME.kernel "$OE_TMP/$KERNEL_NAME"
|
||||||
cp $TARGET_IMG/$IMAGE_NAME.system "$OE_TMP/SYSTEM"
|
cp $TARGET_IMG/$IMAGE_NAME.system "$OE_TMP/SYSTEM"
|
||||||
cp $RELEASE_DIR/splash.png "$OE_TMP"
|
cp $RELEASE_DIR/splash.png "$OE_TMP"
|
||||||
cp $ROOT/$TOOLCHAIN/share/syslinux/vesamenu.c32 "$OE_TMP"
|
cp $ROOT/$TOOLCHAIN/share/syslinux/vesamenu.c32 "$OE_TMP"
|
||||||
@ -204,7 +204,7 @@ EOF
|
|||||||
DEFAULT installer
|
DEFAULT installer
|
||||||
|
|
||||||
LABEL installer
|
LABEL installer
|
||||||
KERNEL /KERNEL
|
KERNEL /$KERNEL_NAME
|
||||||
APPEND boot=UUID=$UUID_SYSTEM installer quiet tty vga=current
|
APPEND boot=UUID=$UUID_SYSTEM installer quiet tty vga=current
|
||||||
EOF
|
EOF
|
||||||
fi
|
fi
|
||||||
@ -217,7 +217,7 @@ EOF
|
|||||||
|
|
||||||
# copy files
|
# copy files
|
||||||
echo "image: copying files to part1..."
|
echo "image: copying files to part1..."
|
||||||
cp $TARGET_IMG/$IMAGE_NAME.kernel "$OE_TMP/kernel.img"
|
cp $TARGET_IMG/$IMAGE_NAME.kernel "$OE_TMP/$KERNEL_NAME"
|
||||||
cp $TARGET_IMG/$IMAGE_NAME.system "$OE_TMP/SYSTEM"
|
cp $TARGET_IMG/$IMAGE_NAME.system "$OE_TMP/SYSTEM"
|
||||||
cp $RELEASE_DIR/3rdparty/bootloader/bootcode.bin "$OE_TMP"
|
cp $RELEASE_DIR/3rdparty/bootloader/bootcode.bin "$OE_TMP"
|
||||||
cp $RELEASE_DIR/3rdparty/bootloader/fixup.dat "$OE_TMP"
|
cp $RELEASE_DIR/3rdparty/bootloader/fixup.dat "$OE_TMP"
|
||||||
@ -240,12 +240,16 @@ elif [ "$BOOTLOADER" = "u-boot" ]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
echo "image: copying files to part1..."
|
echo "image: copying files to part1..."
|
||||||
cp $TARGET_IMG/$IMAGE_NAME.kernel "$OE_TMP/KERNEL"
|
cp $TARGET_IMG/$IMAGE_NAME.kernel "$OE_TMP/$KERNEL_NAME"
|
||||||
cp $TARGET_IMG/$IMAGE_NAME.system "$OE_TMP/SYSTEM"
|
cp $TARGET_IMG/$IMAGE_NAME.system "$OE_TMP/SYSTEM"
|
||||||
cp $RELEASE_DIR/3rdparty/bootloader/u-boot.img "$OE_TMP"
|
if [ -f $RELEASE_DIR/3rdparty/bootloader/u-boot.img ] ; then
|
||||||
|
cp $RELEASE_DIR/3rdparty/bootloader/u-boot.img "$OE_TMP"
|
||||||
|
fi
|
||||||
|
|
||||||
for dtb in $(ls $RELEASE_DIR/3rdparty/bootloader/*.dtb) ; do
|
for dtb in $RELEASE_DIR/3rdparty/bootloader/*.dtb ; do
|
||||||
cp "$dtb" "$OE_TMP"
|
if [ -f $dtb ] ; then
|
||||||
|
cp "$dtb" "$OE_TMP"
|
||||||
|
fi
|
||||||
done
|
done
|
||||||
fi # bootloader
|
fi # bootloader
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user