凌云实验室推出的ARM Linux物联网网关开发板IGKBoard(IoT Gateway Kit Board)项目源码
guowenxue
2021-11-12 c6ad726c839d1b8486daa392fde9347b14f89f8b
tools/lintools/setup_tools.sh
@@ -38,23 +38,40 @@
function install_systools()
{
    arm-linux-gnueabihf-gcc -V > /dev/null 2>&1
    curl -V > /dev/null 2>&1
    if [ $? == 0 ] ;  then
        msg_banner "All development system tools already installed, skip it"
        msg_banner "All system tools already installed, skip it"
        return 0;
    fi
    msg_banner "start apt-get install system devlopment tools(commands)"
    msg_banner "start apt install system tools(commands)"
    systools="gawk wget git diffstat unzip texinfo build-essential chrpath socat libncurses-dev \
    systools="gawk wget git diffstat unzip texinfo build-essential chrpath socat libncurses-dev flex \
        libsdl1.2-dev xterm sed cvs subversion coreutils texi2html docbook-utils python-pysqlite2 tree \
        help2man make gcc g++ desktop-file-utils libgl1-mesa-dev libglu1-mesa-dev mercurial autoconf \
        automake groff curl lzop asciidoc lib32z1 lib32ncurses5-dev libssl-dev autoconf-archive bison flex lzop"
        automake groff curl lzop asciidoc lib32z1 lib32ncurses5-dev libssl-dev autoconf-archive bison "
    devtools="u-boot-tools mtd-utils device-tree-compiler gcc-9-arm-linux-gnueabihf "
    apt-get update > /dev/null 2>&1
    apt-get install -y $systools $devtools
    apt update > /dev/null 2>&1
    apt install -y $systools
}
function install_crosstool()
{
    arm-linux-gnueabihf-gcc -v > /dev/null 2>&1
    if [ $? == 0 ] ;  then
        msg_banner "All development tools already installed, skip it"
        return 0;
    fi
    msg_banner "start apt install devlopment tools(commands)"
    devtools="u-boot-tools mtd-utils device-tree-compiler gcc-arm-linux-gnueabihf g++-arm-linux-gnueabihf \
        binfmt-support qemu qemu-user-static debootstrap debian-archive-keyring "
    apt install -y $devtools
    #sudo update-alternatives --install /usr/bin/arm-linux-gnueabihf-gcc arm-linux-gnueabihf-gcc /usr/bin/arm-linux-gnueabihf-gcc-9 10
}
function install_buildroot()
@@ -67,7 +84,7 @@
    BUILDROOT_DLADDR=${LYFTP_PUB}/$BUILDROOT_TAR
    if [ -d ${BUILDROOT_PATH}/${BUILDROOT_NAME} ] ; then
        msg_banner "$BUILDROOT_VER already installed to $BUILDROOT_PATH/$BUILDROOT_NAME"
        msg_banner "Buildroot already installed to $BUILDROOT_PATH/$BUILDROOT_NAME"
        return 0;
    fi
@@ -93,5 +110,7 @@
install_systools
install_crosstool
install_buildroot