rm /tmp/modules.tar.gz
fi
- # Switch to latest kernel and DTB:
- ssh root@${EVK_IP} "sed -i -e 's@^DEFAULT.*@DEFAULT test@' /boot/extlinux/extlinux.conf"
+ # Determine if using extlinux on target:
+ ssh -q root@${EVK_IP} [[ -f /boot/extlinux/extlinux.conf ]] && EXTLINUX=1 || EXTLINUX=0;
+
+ if [ "${EXTLINUX}" = "1" ]; then
+ # Switch to latest kernel and DTB:
+ ssh root@${EVK_IP} "sed -i -e 's@^DEFAULT.*@DEFAULT test@' /boot/extlinux/extlinux.conf"
+ fi
if [ x"${reboot}" = x"1" ]; then
ssh root@${EVK_IP} "reboot"