##// END OF EJS Templates
Merge pull request #1 from drtyhlpr/master...
burnbabyburn -
r273:c4c87030e1e5 Fusion
parent child
Show More
@@ -69,6 +69,11 if [ "$ENABLE_UBOOT" = true ] ; then
69 69 # Set mkfile to use the correct dtb file
70 70 sed -i "s/^\(setenv dtbfile \).*/\1${DTB_FILE}/" "${BOOT_DIR}/uboot.mkimage"
71 71
72 # Set mkfile to use the correct mach id
73 if [ "$ENABLE_QEMU" = true ] ; then
74 sed -i "s/^\(setenv machid \).*/\10x000008e0/" "${BOOT_DIR}/uboot.mkimage"
75 fi
76
72 77 # Set mkfile to use kernel image
73 78 sed -i "s/^\(fatload mmc 0:1 \${kernel_addr_r} \).*/\1${KERNEL_IMAGE}/" "${BOOT_DIR}/uboot.mkimage"
74 79
@@ -255,32 +255,31 set +x
255 255
256 256 # Set Raspberry Pi model specific configuration
257 257 if [ "$RPI_MODEL" = 0 ] ; then
258 DTB_FILE=${RPI2_DTB_FILE}
259 UBOOT_CONFIG=${RPI2_UBOOT_CONFIG}
258 DTB_FILE=${RPI0_DTB_FILE}
259 UBOOT_CONFIG=${RPI0_UBOOT_CONFIG}
260 260 elif [ "$RPI_MODEL" = 1 ] ; then
261 DTB_FILE=${RPI2_DTB_FILE}
262 UBOOT_CONFIG=${RPI2_UBOOT_CONFIG}
261 DTB_FILE=${RPI1_DTB_FILE}
262 UBOOT_CONFIG=${RPI1_UBOOT_CONFIG}
263 263 elif [ "$RPI_MODEL" = 1P ] ; then
264 DTB_FILE=${RPI2_DTB_FILE}
265 UBOOT_CONFIG=${RPI2_UBOOT_CONFIG}
264 DTB_FILE=${RPI1P_DTB_FILE}
265 UBOOT_CONFIG=${RPI1P_UBOOT_CONFIG}
266 266 elif [ "$RPI_MODEL" = 2 ] ; then
267 267 DTB_FILE=${RPI2_DTB_FILE}
268 268 UBOOT_CONFIG=${RPI2_UBOOT_CONFIG}
269 269 elif [ "$RPI_MODEL" = 3 ] ; then
270 270 DTB_FILE=${RPI3_DTB_FILE}
271 271 UBOOT_CONFIG=${RPI3_UBOOT_CONFIG}
272 BUILD_KERNEL=true
273 272 elif [ "$RPI_MODEL" = 3P ] ; then
274 273 DTB_FILE=${RPI3P_DTB_FILE}
275 274 UBOOT_CONFIG=${RPI3P_UBOOT_CONFIG}
276 BUILD_KERNEL=true
277 275 else
278 276 echo "error: Raspberry Pi model ${RPI_MODEL} is not supported!"
279 277 exit 1
280 278 fi
281 279
282 280 # Check if the internal wireless interface is supported by the RPi model
283 if [ "$ENABLE_WIRELESS" = true ] && [ "$RPI_MODEL" = 2 ]; then
281 if [ "$ENABLE_WIRELESS" = true ] && ([ "$RPI_MODEL" = 1 ] || [ "$RPI_MODEL" = 1P ] || [ "$RPI_MODEL" = 2 ]); then
282
284 283 echo "error: The selected Raspberry Pi model has no internal wireless interface"
285 284 exit 1
286 285 fi
@@ -301,9 +300,15 fi
301 300 # Add packages required for kernel cross compilation
302 301 if [ "$BUILD_KERNEL" = true ] ; then
303 302 if [ "$KERNEL_ARCH" = "arm" ] ; then
304 REQUIRED_PACKAGES="${REQUIRED_PACKAGES} crossbuild-essential-armhf"
305 else
306 REQUIRED_PACKAGES="${REQUIRED_PACKAGES} crossbuild-essential-arm64"
303 if [ "$RELEASE_ARCH" = "armel" ]; then
304 REQUIRED_PACKAGES="${REQUIRED_PACKAGES} crossbuild-essential-armel"
305 fi
306 if [ "$RELEASE_ARCH" = "armhf" ]; then
307 REQUIRED_PACKAGES="${REQUIRED_PACKAGES} crossbuild-essential-armhf"
308 fi
309 if [ "$RELEASE_ARCH" = "arm64" ]; then
310 REQUIRED_PACKAGES="${REQUIRED_PACKAGES} crossbuild-essential-arm64"
311 fi
307 312 fi
308 313 fi
309 314
@@ -336,7 +341,7 fi
336 341
337 342 # Add device-tree-compiler required for building the U-Boot bootloader
338 343 if [ "$ENABLE_UBOOT" = true ] ; then
339 APT_INCLUDES="${APT_INCLUDES},device-tree-compiler"
344 APT_INCLUDES="${APT_INCLUDES},device-tree-compiler,bison,flex"
340 345 fi
341 346
342 347 # Check if root SSH (v2) public key file exists
@@ -525,6 +530,8 fi
525 530
526 531 # Configure qemu compatible kernel
527 532 if [ "$ENABLE_QEMU" = true ] ; then
533 DTB_FILE=vexpress-v2p-ca15_a7.dtb
534 UBOOT_CONFIG=vexpress_ca15_tc2_defconfig
528 535 KERNEL_DEFCONFIG="vexpress_defconfig"
529 536 if [ "$KERNEL_MENUCONFIG" = false ] ; then
530 537 KERNEL_OLDDEFCONFIG=true
@@ -626,6 +633,19 if [ "$ENABLE_QEMU" = true ] ; then
626 633 done
627 634 fi
628 635
636 # Copy u-boot files to QEMU directory
637 if [ "$ENABLE_UBOOT" = true ] ; then
638 if [ -f "${BOOT_DIR}/u-boot.bin" ] ; then
639 install_readonly "${BOOT_DIR}/u-boot.bin" "${BASEDIR}/qemu/u-boot.bin"
640 fi
641 if [ -f "${BOOT_DIR}/uboot.mkimage" ] ; then
642 install_readonly "${BOOT_DIR}/uboot.mkimage" "${BASEDIR}/qemu/uboot.mkimage"
643 fi
644 if [ -f "${BOOT_DIR}/boot.scr" ] ; then
645 install_readonly "${BOOT_DIR}/boot.scr" "${BASEDIR}/qemu/boot.scr"
646 fi
647 fi
648
629 649 # Copy initramfs to QEMU directory
630 650 if [ -f "${BOOT_DIR}/initramfs-${KERNEL_VERSION}" ] ; then
631 651 install_readonly "${BOOT_DIR}/initramfs-${KERNEL_VERSION}" "${BASEDIR}/qemu/initramfs-${KERNEL_VERSION}"
General Comments 0
Vous devez vous connecter pour laisser un commentaire. Se connecter maintenant