Compile K2P's LEDE firmware
The LEDE firmware is the OpenWRT firmware modified by L.
Note:
Do not use the root user to compile! ! !
Domestic users had better prepare a ladder before compiling.
Default login IP 192.168.1.1 password password
environment:
Ubuntu 18.04 64-bit
scientific Internet environment (global)
Resource link:
Large LEDE library:
https://github.com/coolsnowwolf/lede.git
Scientific Firmware Libraries:
https://github.com/fw876/helloworld.git
Start the first compilation
The first compilation can be performed directly according to the operation steps of L major. It is recommended to perform a single-threaded compilation according to the operation steps of L major, and only need to select the corresponding device parameters.
1. Command line input
sudo apt-get update
to update the ubuntu dependency library
2. Enter the following code to install the required dependencies
sudo apt-get -y install build-essential asciidoc binutils bzip2 gawk gettext git libncurses5-dev libz-dev patch python3 python2.7 unzip zlib1g-dev lib32gcc1 libc6-dev-i386 subversion flex uglifyjs git-core gcc-multilib p7zip p7zip-full msmtp libssl-dev texinfo libglib2.0-dev xmlto qemu-utils upx libelf-dev autoconf automake libtool autopoint device-tree-compiler g++-multilib antlr3 gperf wget curl swig rsync
3. Use the following command to download the source code to the system main directory
git clone https://github.com/coolsnowwolf/lede
4. Use the following command to enter the downloaded source code directory
cd lede
5. Update the libraries contained in the configuration file
./scripts/feeds update -a
install library
./scripts/feeds install -a
6. Enter the following command in the terminal to open the configuration interface. After the first compilation and opening, just set the first three items and select the corresponding model of equipment.
make menuconfig
7. Download the dl library (please try to surf the Internet scientifically as much as possible in China)
make -j8 download V=s
8. Enter the following command (-j1 is followed by the number of threads. It is recommended to use a single thread for the first compilation, and it takes about two hours for the intel-8250u single thread) to start compiling the firmware you want.
make -j1 V=s
Wait for the end of the operation to complete the first compilation, and then you can start the compilation of custom firmware.
Compilation of custom firmware
(Take scientific firmware as an example)
1. After entering the lede folder through the cd lede command, use the "ls" command to view the files contained in the lede folder
2. Use the vim editor to edit the library configuration file "feeds.conf.default"
vim feeds.conf.default
After entering the file, add the last line of code, the link is the scientific firmware link given at the beginning of the article (the library with large L size does not have scientific firmware by default, you need to add it yourself) The vim
editor operation commands are:
"i" to modify and edit;
press after editing ESC key to exit editing;
shift+: query status;
input wq! to save and exit, and exit as q!
ps: If the library cannot be found during compilation, replace https in the link after the corresponding package name above with git. 3.
Next, enter the following commands in sequence
./scripts/feeds update -a
./scripts/feeds install -a
make menuconfig
4. After entering the configuration page, select LuCI->3. Applications, and select the corresponding firmware in it. After selecting the
firmware, exit continuously until the main interface of the terminal
5. Enter the following command to download and update the dl library
make -j8 download V=s
6. Compile with maximum performance
make -j$(($(nproc) + 1)) V=s
7. Compiled and output firmware
After compiling, the output path: lede/bin/targets