Openwrt:build dependency:please do not compile as root solution

Source: Internet
Author: User
ƒ


Compile OpenWrt appears:



Collecting Package Info:done
Checking ' Working-make ' ... ok.
Checking ' Case-sensitive-fs ' ... ok.
Checking ' getopt ' ... ok.
Checking ' fileutils ' ... ok.
Checking ' WORKING-GCC ' ... ok.
Checking ' working-g++ ' ... ok.
Checking ' ncurses ' ... ok.
Checking ' zlib ' ... ok.
Checking ' gawk ' ... ok.
Checking ' unzip ' ... ok.
Checking ' bzip2 ' ... ok.
Checking ' patch ' ... ok.
Checking ' perl ' ... ok.
Checking ' python ' ... ok.
Checking ' wget ' ... ok.
Checking ' git ' ... ok.
Checking ' Gnutar ' ... ok.
Checking ' svn ' ... ok.
Checking ' Gnu-find ' ... ok.
Checking ' getopt-extended ' ... ok.
Checking ' OCAMLC ' ... ok.
Checking ' Ocamlfind ' ... ok.
Checking ' Non-root ' ... failed.

Build Dependency:please does not compile as root.

Prerequisite check failed. Use Force=1 to override.
MAKE[1]: * * * [tmp/.prereq-build] Error 1
Make: * * * [deconfig] Error 2






This error occurs because OpenWrt checks the permissions by default for security purposes and recommends that you compile them with non-root permissions, which are set under the INCLUDE/PREREQ-BUILD.MK path
Workaround:



command-line Input VI include/prereq-build.mk



In the Prereq-build.mk file, comment out the line that is annotated in the following figure (plus the # annotation symbol in front)







And then re-make Defconfig in the QSDK directory









Checking whether Mknod can create FIFO without root privileges ... configure:error:in '/work/openwrt/build_dir/host/tar-1 .28 ':
Configure:error:you should not run configure as root (set force_unsafe_configure=1 in environment to bypass this check)



Try the command indicated in the error message:



Export force_unsafe_configure=1 && make


This being said, it is true the "unsafe configure" requirement seems a bit strange. Double-check the log (Config.log) and the If there is something more explicit in there.




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.