mirror of
https://github.com/Fishwaldo/build.git
synced 2025-07-23 21:39:02 +00:00
RK3288 revert packaging script patch
This commit is contained in:
parent
7ad9174c7d
commit
10b60f3112
1 changed files with 9 additions and 34 deletions
|
@ -1,5 +1,5 @@
|
|||
diff --git a/scripts/package/builddeb b/scripts/package/builddeb
|
||||
index 6c3b038..34c4006 100755
|
||||
index 6c3b038..cc9b3c0 100755
|
||||
--- a/scripts/package/builddeb
|
||||
+++ b/scripts/package/builddeb
|
||||
@@ -27,6 +27,28 @@ create_package() {
|
||||
|
@ -23,7 +23,7 @@ index 6c3b038..34c4006 100755
|
|||
+
|
||||
+ # Create postinstall script for headers
|
||||
+ if [[ "$1" == *headers* ]]; then
|
||||
+ echo "cd /usr/src/linux-headers-$version; echo \"Compiling headers - please wait ...\"; find -type f -exec touch {} +;make -s scripts >/dev/null 2>&1" >> $pdir/DEBIAN/postinst
|
||||
+ echo "cd /usr/src/linux-headers-$version; echo \"Compiling headers - please wait ...\"; make -s scripts >/dev/null 2>&1" >> $pdir/DEBIAN/postinst
|
||||
+ echo "exit 0" >> $pdir/DEBIAN/postinst
|
||||
+ chmod 775 $pdir/DEBIAN/postinst
|
||||
+ fi
|
||||
|
@ -49,15 +49,6 @@ index 6c3b038..34c4006 100755
|
|||
dbg_packagename=$packagename-dbg
|
||||
debarch=
|
||||
forcearch=
|
||||
@@ -114,7 +138,7 @@ case $ARCH in
|
||||
um)
|
||||
installed_image_path="usr/bin/linux-$version"
|
||||
;;
|
||||
-parisc|mips|powerpc)
|
||||
+parisc|mips|powerpc|arm64)
|
||||
installed_image_path="boot/vmlinux-$version"
|
||||
;;
|
||||
*)
|
||||
@@ -124,7 +148,9 @@ esac
|
||||
BUILD_DEBUG="$(grep -s '^CONFIG_DEBUG_INFO=y' $KCONFIG_CONFIG || true)"
|
||||
|
||||
|
@ -69,20 +60,7 @@ index 6c3b038..34c4006 100755
|
|||
mkdir -m 755 -p "$tmpdir/DEBIAN"
|
||||
mkdir -p "$tmpdir/lib" "$tmpdir/boot"
|
||||
mkdir -p "$fwdir/lib/firmware/$version/"
|
||||
@@ -143,9 +169,10 @@ else
|
||||
fi
|
||||
# Not all arches include the boot path in KBUILD_IMAGE
|
||||
if [ -e $KBUILD_IMAGE ]; then
|
||||
- cp $KBUILD_IMAGE "$tmpdir/$installed_image_path"
|
||||
+#Forcing KBUILD_MAGE reference to Image instead of zImage.. Armbian LINUX_KERNEL_TYPE=Image not being honored
|
||||
+ cp Image "$tmpdir/$installed_image_path"
|
||||
else
|
||||
- cp arch/$ARCH/boot/$KBUILD_IMAGE "$tmpdir/$installed_image_path"
|
||||
+ cp arch/$ARCH/boot/Image "$tmpdir/$installed_image_path"
|
||||
fi
|
||||
|
||||
if grep -q "^CONFIG_OF=y" $KCONFIG_CONFIG ; then
|
||||
@@ -183,6 +210,11 @@ if grep -q '^CONFIG_MODULES=y' $KCONFIG_CONFIG ; then
|
||||
@@ -183,6 +209,11 @@ if grep -q '^CONFIG_MODULES=y' $KCONFIG_CONFIG ; then
|
||||
fi
|
||||
fi
|
||||
|
||||
|
@ -94,7 +72,7 @@ index 6c3b038..34c4006 100755
|
|||
if [ "$ARCH" != "um" ]; then
|
||||
$MAKE headers_check KBUILD_SRC=
|
||||
$MAKE headers_install KBUILD_SRC= INSTALL_HDR_PATH="$libc_headers_dir/usr"
|
||||
@@ -195,7 +227,7 @@ fi
|
||||
@@ -195,7 +226,7 @@ fi
|
||||
# so do we; recent versions of dracut and initramfs-tools will obey this.
|
||||
debhookdir=${KDEB_HOOKDIR:-/etc/kernel}
|
||||
if grep -q '^CONFIG_BLK_DEV_INITRD=y' $KCONFIG_CONFIG; then
|
||||
|
@ -103,7 +81,7 @@ index 6c3b038..34c4006 100755
|
|||
else
|
||||
want_initrd=No
|
||||
fi
|
||||
@@ -207,9 +239,11 @@ for script in postinst postrm preinst prerm ; do
|
||||
@@ -207,9 +238,11 @@ for script in postinst postrm preinst prerm ; do
|
||||
set -e
|
||||
|
||||
# Pass maintainer script parameters to hook scripts
|
||||
|
@ -115,7 +93,7 @@ index 6c3b038..34c4006 100755
|
|||
export INITRD=$want_initrd
|
||||
|
||||
test -d $debhookdir/$script.d && run-parts --arg="$version" --arg="/$installed_image_path" $debhookdir/$script.d
|
||||
@@ -218,6 +252,58 @@ EOF
|
||||
@@ -218,6 +251,55 @@ EOF
|
||||
chmod 755 "$tmpdir/DEBIAN/$script"
|
||||
done
|
||||
|
||||
|
@ -126,17 +104,14 @@ index 6c3b038..34c4006 100755
|
|||
+sed -e "s/exit 0//g" -i $tmpdir/DEBIAN/postinst
|
||||
+cat >> $tmpdir/DEBIAN/postinst <<EOT
|
||||
+if [ "\$(grep nand /proc/partitions)" != "" ] && [ "\$(grep mmc /proc/partitions)" = "" ]; then
|
||||
+mkimage -A arm -O linux -T kernel -C gzip -a "0x40008000" -e "0x40008000" -n "Linux kernel" -d /$installed_image_path /boot/uImage > /dev/null 2>&1
|
||||
+mkimage -A arm -O linux -T kernel -C none -a "0x40008000" -e "0x40008000" -n "Linux kernel" -d /$installed_image_path /boot/uImage > /dev/null 2>&1
|
||||
+cp /boot/uImage /tmp/uImage
|
||||
+##copy uncompressed Kernel Image w/o Uboot for espressobin--gzip compressed forced above for mkimage
|
||||
+cp $installed_image_path /tmp/Image
|
||||
+sync
|
||||
+mountpoint -q /boot || mount /boot
|
||||
+cp /tmp/uImage /boot/uImage
|
||||
+cp /tmp/Image /boot/Image
|
||||
+rm -f /$installed_image_path
|
||||
+else
|
||||
+ln -sf $(basename $installed_image_path) /boot/Image > /dev/null 2>&1 || mv /$installed_image_path /boot/Image
|
||||
+ln -sf $(basename $installed_image_path) /boot/zImage > /dev/null 2>&1 || mv /$installed_image_path /boot/zImage
|
||||
+fi
|
||||
+touch /boot/.next
|
||||
+exit 0
|
||||
|
@ -164,7 +139,7 @@ index 6c3b038..34c4006 100755
|
|||
+bootfstype=\$(blkid -s TYPE -o value \$boot_partition)
|
||||
+if [ "\$bootfstype" = "vfat" ]; then
|
||||
+umount /boot;
|
||||
+rm -f /boot/System.map* /boot/config* /boot/vmlinuz* /boot/zImage /boot/uImage /boot/Image
|
||||
+rm -f /boot/System.map* /boot/config* /boot/vmlinuz* /boot/zImage /boot/uImage
|
||||
+fi
|
||||
+}
|
||||
+mountpoint -q /boot && check_and_unmount
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue