From f9905513eedf5fa779618c684ba510975adab816 Mon Sep 17 00:00:00 2001 From: guowenxue <guowenxue@gmail.com> Date: Mon, 12 Aug 2019 15:41:46 +0800 Subject: [PATCH] update busybox defaut configure --- linux-bsp/build.sh | 15 +++++++++------ 1 files changed, 9 insertions(+), 6 deletions(-) diff --git a/linux-bsp/build.sh b/linux-bsp/build.sh index 774f598..ed8273a 100755 --- a/linux-bsp/build.sh +++ b/linux-bsp/build.sh @@ -10,10 +10,13 @@ PROJ_PATH=`pwd` +CROSSTOOL=/opt/buildroot/cortex-a5/bin/arm-linux- + BOARD=sama5d4 PACK_PATH=${PROJ_PATH}/tarballs PATCH_PATH=${PROJ_PATH}/patches PATCH_SUFIX=${BOARD}.patch + ROOTFS_SRC=rootfs @@ -85,6 +88,10 @@ if [ -f ${PATCH_PATH}/${SRC_DIR}-${PATCH_SUFIX} ] ; then show_banner "| patch for ${SRC_DIR} |" + + # update cross compiler + sed -i -e "s|^+CROSSTOOL=.*|+CROSSTOOL=${CROSSTOOL}|g" ${PATCH_PATH}/${SRC_DIR}-${PATCH_SUFIX} + patch -p1 < ${PATCH_PATH}/${SRC_DIR}-${PATCH_SUFIX} fi else @@ -152,12 +159,8 @@ function build_rootfs() { if [ ! -d ${ROOTFS_SRC} ] ; then - if [ `id -u` != 0 ] ; then - printf "\nERROR: decompress rootfs need root privilege, please use sudo!\n\n" - exit ; - fi - - tar -xJf ${PACK_PATH}/${ROOTFS_SRC}.tar.xz + printf "\nWARNNING: decompress rootfs need root privilege, please input sudo passwd!\n\n" + sudo tar -xJf ${PACK_PATH}/${ROOTFS_SRC}.tar.xz fi show_banner "| start build rootfs image... |" -- Gitblit v1.9.1