aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSean Cross <xobs@kosagi.com>2014-04-22 13:30:08 +0800
committerSean Cross <xobs@kosagi.com>2014-10-15 21:01:22 +0800
commit94eadc70f63464a25657048c0396db7755a36de8 (patch)
tree810a9741f2c725f67d04d66c114f3fb26b1bd6a6
parent7aa41c253c0c9d3d83d43267c28d24cbdcaea0df (diff)
downloadnovena-linux-94eadc70f63464a25657048c0396db7755a36de8.tar.gz
novena-linux-94eadc70f63464a25657048c0396db7755a36de8.tar.bz2
novena-linux-94eadc70f63464a25657048c0396db7755a36de8.zip
deb-pkg: Add support for KBUILD_DTB
Enable packaging of dtb files alongsde kernel. If KBUILD_DTB is specified, then copy that dtb file to the resulting kernel package. Signed-off-by: Sean Cross <xobs@kosagi.com>
-rw-r--r--scripts/package/builddeb11
1 files changed, 11 insertions, 0 deletions
diff --git a/scripts/package/builddeb b/scripts/package/builddeb
index 35d5a5877d0..39e1136b931 100644
--- a/scripts/package/builddeb
+++ b/scripts/package/builddeb
@@ -97,12 +97,15 @@ fi
case $ARCH in
um)
installed_image_path="usr/bin/linux-$version"
+ installed_dtb_path="usr/bin/linux-$version.dtb"
;;
parisc|mips|powerpc)
installed_image_path="boot/vmlinux-$version"
+ installed_dtb_path="boot/vmlinuz-$version.dtb"
;;
*)
installed_image_path="boot/vmlinuz-$version"
+ installed_dtb_path="boot/vmlinuz-$version.dtb"
esac
BUILD_DEBUG="$(grep -s '^CONFIG_DEBUG_INFO=y' $KCONFIG_CONFIG || true)"
@@ -143,6 +146,14 @@ else
cp arch/$ARCH/boot/$KBUILD_IMAGE "$tmpdir/$installed_image_path"
fi
+if [ ! -z $KBUILD_DTB ]; then
+ if [ -e $KBUILD_DTB ]; then
+ cp $KBUILD_DTB "$tmpdir/$installed_dtb_path"
+ else
+ cp arch/$ARCH/boot/dts/$KBUILD_DTB "$tmpdir/$installed_dtb_path"
+ fi
+fi
+
if grep -q '^CONFIG_MODULES=y' $KCONFIG_CONFIG ; then
INSTALL_MOD_PATH="$tmpdir" $MAKE KBUILD_SRC= modules_install
rm -f "$tmpdir/lib/modules/$version/build"