Edited control and rules files to allow for FIT image signing.

Change-Id: I8c01bd99c5d36730dbc699bc0d57940aea46ac58
diff --git a/debian/control b/debian/control
index ff7ca93..f836b2b 100644
--- a/debian/control
+++ b/debian/control
@@ -1,6 +1,6 @@
 Source: linux-mtk
 Maintainer: AIY Projects <support-aiyprojects@google.com>
-Build-Depends: debhelper (>= 10), bc, cpio, debhelper, gcc-aarch64-linux-gnu, libssl-dev, python, gcc-arm-linux-gnueabihf, u-boot-mkimage
+Build-Depends: debhelper (>= 10), bc, cpio, debhelper, gcc-aarch64-linux-gnu, libssl-dev:native, python, gcc-arm-linux-gnueabihf, u-boot-mkimage, liblz4-tool, boot-keys, device-tree-compiler
 Section: misc
 Priority: optional
 
diff --git a/debian/rules b/debian/rules
index 3a65e27..cfa5252 100755
--- a/debian/rules
+++ b/debian/rules
@@ -7,11 +7,11 @@
 VERSION := 4.4.22-aiy
 
 ARCH := arm64
-
+CROSS_COMPILE := aarch64-linux-gnu-
 
 KERNEL_OPTIONS := \
-	ARCH=arm64 \
-	CROSS_COMPILE=aarch64-linux-gnu- \
+	ARCH=${ARCH} \
+	CROSS_COMPILE=${CROSS_COMPILE} \
 	LOCALVERSION=-aiy
 
 LDFLAGS :=
@@ -29,6 +29,13 @@
 override_dh_auto_build:
 	+make ${KERNEL_OPTIONS} mt8167s_excelsior_defconfig
 	+make ${KERNEL_OPTIONS} -j$(shell nproc) Image modules dtbs
+	${CROSS_COMPILE}objcopy -O binary -R .note -R .comment -S vmlinux linux.bin
+
+	compress_lz4 linux.bin
+
+	cp /boot/kernel-fit-image.its .
+	mtk-mkimage -D "-I dts -O dtb -p 1024" -k /boot/keys -f kernel-fit-image.its boot.img
 
 override_dh_auto_install:
-	echo "Built kernel!"
+	install -d $(DESTDIR)/boot
+	install -p -m 655 boot.img $(DESTDIR)/boot