OpenWrt compiling the script to the end

Source: Internet
Author: User

Compiling openwrt in the office takes a long time, for two reasons.

One is the office network environment is bad, often disconnected do not say, many websites often do not connect, not hit 404 is the DNS resolution failure and so on.

Second, the first time to compile openwrt need to download a large number of files from the Internet, such as Build_dir under the file is more than 3.4G.

[Email protected]:~/openwrt_mtk/openwrt-2.6.36$ du-sh build_dir/
3.4G build_dir/
[email protected]:~/openwrt_mtk/openwrt-2.6.36$ ls./build_dir
Host
target-mipsel_24kec+dsp_uclibc-0.9.33.2
toolchain-mipsel_24kec+dsp_gcc-4.6-linaro_uclibc-0.9.33.2

Have to do a simple and rough compilation script: always compile until successful.

#! /bin/bash# compile to the end script: always compile until successful # Create log file logname=log_$ (date +%y%m%d) touch logname# compile make clean# bind error output 2 to correct output 1 and send the correct output to $ Lognamemake v=s > ${logname} 2>&1while [' Echo $? '! = 0]; Do make        v=s >> ${logname} 2>&1done

OpenWrt compiling the script to the end

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.