coolsnowwolf / lede

Lean's LEDE source
Other
29.6k stars 19.51k forks source link

红米 ac2100 编译的底包有问题? #10325

Closed miaoermua closed 1 year ago

miaoermua commented 1 year ago

1.关于你要提交的问题

Q:是否搜索了issue (使用 "x" 选择)

2. 详细叙述

(1) 具体问题

在使用 063f51c24 编译固件时,编译是成功了但是 initramfs-kernel.bin 出奇的大 37.4M,squashfs-sysupgrade.bin 则只有 37.9M,initramfs-kernel.bin 在 breed 刷是刷进了但 System 灯只蓝不变黄色闪烁,使用 红米 小米 AC2100 刷BREED与OpenWrt教程 的方法和包安装他的 initramfs-kernel.bin 底包内核 5.10.116 在里面升级到我编译的固件则正常,不知道是底包问题还是我编译的时候操作问题,底包不应该这么大吧(……

如 issues 过于低级请关闭,有不对请指正表明需要什么资料。

(2) 路由器型号和固件版本

红米 ac2100 / Xiaomi Redmi Router AC2100

固件版本 | OpenWrt R22.10.20 / LuCI Master (git-22.289.58375-2a380a3) 内核版本 | 5.4.219

(3) 详细日志

成功编译的

……
make[7]: Entering directory '/home/by/lede/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/tmp/openwrt-ramips-mt7621-xiaomi_redmi-router-ac2100-initramfs-kernel.bin.src'
rm -f loader *.elf *.bin *.o
mipsel-openwrt-linux-musl-gcc -D__KERNEL__ -Wall -Wstrict-prototypes -Wno-trigraphs -Os -fno-strict-aliasing -fno-common -fomit-frame-pointer -G 0 -mno-abicalls -fno-pic -ffunction-sections -pipe -mlong-calls -fno-common -ffreestanding -fhonour-copts -nostartfiles -mabi=32 -march=mips32r2 -Wa,-32 -Wa,-march=mips32r2 -Wa,-mips32r2 -Wa,--trap -D_LZMA_PROB32 -flto -DCONFIG_ICACHE_SIZE="(32 * 1024)" -DCONFIG_DCACHE_SIZE="(16 * 1024)" -DCONFIG_CACHELINE_SIZE=32 -DLZMA_WRAPPER=1 -DLOADADDR=0x80001000 -D__ASSEMBLY__ -c -o head.o head.S
mipsel-openwrt-linux-musl-gcc -D__KERNEL__ -Wall -Wstrict-prototypes -Wno-trigraphs -Os -fno-strict-aliasing -fno-common -fomit-frame-pointer -G 0 -mno-abicalls -fno-pic -ffunction-sections -pipe -mlong-calls -fno-common -ffreestanding -fhonour-copts -nostartfiles -mabi=32 -march=mips32r2 -Wa,-32 -Wa,-march=mips32r2 -Wa,-mips32r2 -Wa,--trap -D_LZMA_PROB32 -flto -DCONFIG_ICACHE_SIZE="(32 * 1024)" -DCONFIG_DCACHE_SIZE="(16 * 1024)" -DCONFIG_CACHELINE_SIZE=32 -DLZMA_WRAPPER=1 -DLOADADDR=0x80001000 -c -o loader.o loader.c
mipsel-openwrt-linux-musl-gcc -D__KERNEL__ -Wall -Wstrict-prototypes -Wno-trigraphs -Os -fno-strict-aliasing -fno-common -fomit-frame-pointer -G 0 -mno-abicalls -fno-pic -ffunction-sections -pipe -mlong-calls -fno-common -ffreestanding -fhonour-copts -nostartfiles -mabi=32 -march=mips32r2 -Wa,-32 -Wa,-march=mips32r2 -Wa,-mips32r2 -Wa,--trap -D_LZMA_PROB32 -flto -DCONFIG_ICACHE_SIZE="(32 * 1024)" -DCONFIG_DCACHE_SIZE="(16 * 1024)" -DCONFIG_CACHELINE_SIZE=32 -DLZMA_WRAPPER=1 -DLOADADDR=0x80001000 -c -o cache.o cache.c
mipsel-openwrt-linux-musl-gcc -D__KERNEL__ -Wall -Wstrict-prototypes -Wno-trigraphs -Os -fno-strict-aliasing -fno-common -fomit-frame-pointer -G 0 -mno-abicalls -fno-pic -ffunction-sections -pipe -mlong-calls -fno-common -ffreestanding -fhonour-copts -nostartfiles -mabi=32 -march=mips32r2 -Wa,-32 -Wa,-march=mips32r2 -Wa,-mips32r2 -Wa,--trap -D_LZMA_PROB32 -flto -DCONFIG_ICACHE_SIZE="(32 * 1024)" -DCONFIG_DCACHE_SIZE="(16 * 1024)" -DCONFIG_CACHELINE_SIZE=32 -DLZMA_WRAPPER=1 -DLOADADDR=0x80001000 -c -o board-mt7621.o board-mt7621.c
mipsel-openwrt-linux-musl-gcc -D__KERNEL__ -Wall -Wstrict-prototypes -Wno-trigraphs -Os -fno-strict-aliasing -fno-common -fomit-frame-pointer -G 0 -mno-abicalls -fno-pic -ffunction-sections -pipe -mlong-calls -fno-common -ffreestanding -fhonour-copts -nostartfiles -mabi=32 -march=mips32r2 -Wa,-32 -Wa,-march=mips32r2 -Wa,-mips32r2 -Wa,--trap -D_LZMA_PROB32 -flto -DCONFIG_ICACHE_SIZE="(32 * 1024)" -DCONFIG_DCACHE_SIZE="(16 * 1024)" -DCONFIG_CACHELINE_SIZE=32 -DLZMA_WRAPPER=1 -DLOADADDR=0x80001000 -c -o printf.o printf.c
mipsel-openwrt-linux-musl-gcc -D__KERNEL__ -Wall -Wstrict-prototypes -Wno-trigraphs -Os -fno-strict-aliasing -fno-common -fomit-frame-pointer -G 0 -mno-abicalls -fno-pic -ffunction-sections -pipe -mlong-calls -fno-common -ffreestanding -fhonour-copts -nostartfiles -mabi=32 -march=mips32r2 -Wa,-32 -Wa,-march=mips32r2 -Wa,-mips32r2 -Wa,--trap -D_LZMA_PROB32 -flto -DCONFIG_ICACHE_SIZE="(32 * 1024)" -DCONFIG_DCACHE_SIZE="(16 * 1024)" -DCONFIG_CACHELINE_SIZE=32 -DLZMA_WRAPPER=1 -DLOADADDR=0x80001000 -c -o LzmaDecode.o LzmaDecode.c
mipsel-openwrt-linux-musl-ld -r -b binary --oformat elf32-tradlittlemips -T lzma-data.lds -o data.o /home/by/lede/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/tmp/openwrt-ramips-mt7621-xiaomi_redmi-router-ac2100-initramfs-kernel.bin
mipsel-openwrt-linux-musl-gcc -D__KERNEL__ -Wall -Wstrict-prototypes -Wno-trigraphs -Os -fno-strict-aliasing -fno-common -fomit-frame-pointer -G 0 -mno-abicalls -fno-pic -ffunction-sections -pipe -mlong-calls -fno-common -ffreestanding -fhonour-copts -nostartfiles -mabi=32 -march=mips32r2 -Wa,-32 -Wa,-march=mips32r2 -Wa,-mips32r2 -Wa,--trap -D_LZMA_PROB32 -flto -DCONFIG_ICACHE_SIZE="(32 * 1024)" -DCONFIG_DCACHE_SIZE="(16 * 1024)" -DCONFIG_CACHELINE_SIZE=32 -DLZMA_WRAPPER=1 -DLOADADDR=0x80001000 -static -Wl,--gc-sections -Wl,-no-warn-mismatch -Wl,-e,startup -T loader.lds -Wl,-Ttext,0x81800000 -flto -fwhole-program -Wl,-z,max-page-size=4096 -o loader head.o loader.o cache.o board-mt7621.o printf.o LzmaDecode.o data.o
mipsel-openwrt-linux-musl-objcopy -O binary -R .reginfo -R .note -R .comment -R .mdebug -R .MIPS.abiflags -S loader loader.bin
mipsel-openwrt-linux-musl-ld -r -b binary --oformat elf32-tradlittlemips -o loader2.o loader.bin
mipsel-openwrt-linux-musl-ld -e startup -T loader2.lds -Ttext 0x80001000 -z max-page-size=4096 -o loader.elf loader2.o
make[7]: Leaving directory '/home/by/lede/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/tmp/openwrt-ramips-mt7621-xiaomi_redmi-router-ac2100-initramfs-kernel.bin.src'
make[6]: Leaving directory '/home/by/lede/target/linux/ramips/image/lzma-loader'
mv "/home/by/lede/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/tmp/openwrt-ramips-mt7621-xiaomi_redmi-router-ac2100-initramfs-kernel.bin.bin" "/home/by/lede/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/tmp/openwrt-ramips-mt7621-xiaomi_redmi-router-ac2100-initramfs-kernel.bin"
rm -rf /home/by/lede/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/tmp/openwrt-ramips-mt7621-xiaomi_redmi-router-ac2100-initramfs-kernel.bin.src
mkimage -A mips -O linux -T kernel -C none -a 0x80001000 -e 0x80001000 -n 'MIPS OpenWrt Linux-5.4.219'   -d /home/by/lede/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/tmp/openwrt-ramips-mt7621-xiaomi_redmi-router-ac2100-initramfs-kernel.bin /home/by/lede/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/tmp/openwrt-ramips-mt7621-xiaomi_redmi-router-ac2100-initramfs-kernel.bin.new
Image Name:   MIPS OpenWrt Linux-5.4.219
Created:      Tue Oct 25 04:40:31 2022
Image Type:   MIPS Linux Kernel Image (uncompressed)
Data Size:    39169142 Bytes = 38251.12 KiB = 37.35 MiB
Load Address: 80001000
Entry Point:  80001000
mv /home/by/lede/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/tmp/openwrt-ramips-mt7621-xiaomi_redmi-router-ac2100-initramfs-kernel.bin.new /home/by/lede/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/tmp/openwrt-ramips-mt7621-xiaomi_redmi-router-ac2100-initramfs-kernel.bin
cp /home/by/lede/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/tmp/openwrt-ramips-mt7621-xiaomi_redmi-router-ac2100-initramfs-kernel.bin /home/by/lede/bin/targets/ramips/mt7621/openwrt-ramips-mt7621-xiaomi_redmi-router-ac2100-initramfs-kernel.bin
IPKG_NO_SCRIPT=1 IPKG_INSTROOT=/home/by/lede/build_dir/target-mipsel_24kc_musl/root.orig-ramips TMPDIR=/home/by/lede/build_dir/target-mipsel_24kc_musl/root.orig-ramips/tmp /home/by/lede/staging_dir/host/bin/opkg --offline-root /home/by/lede/build_dir/target-mipsel_24kc_musl/root.orig-ramips --force-postinstall --add-dest root:/ --add-arch all:100 --add-arch mipsel_24kc:200 list-installed > /home/by/lede/bin/targets/ramips/mt7621/openwrt-ramips-mt7621-xiaomi_redmi-router-ac2100.manifest
make[5]: Leaving directory '/home/by/lede/target/linux/ramips/image'
make[4]: Leaving directory '/home/by/lede/target/linux/ramips'
make[3]: Leaving directory '/home/by/lede/target/linux'
time: target/linux/install#398.05#1592.05#513.69
make[2]: Leaving directory '/home/by/lede'
export MAKEFLAGS= ;make -w -r package/index
make[2]: Entering directory '/home/by/lede'
Generating package index...
Generating index for package ./base-files_52-r5317-063f51c24_mipsel_24kc.ipk
Generating index for package ./block-mount_2021-08-14-2e3aca29-2_mipsel_24kc.ipk
Generating index for package ./dropbear_2022.82-2_mipsel_24kc.ipk
Generating index for package ./fstools_2021-08-14-2e3aca29-2_mipsel_24kc.ipk
Generating index for package ./fwtool_2019-11-12-8f7fe925-1_mipsel_24kc.ipk
Generating index for package ./ip6tables_1.8.7-1_mipsel_24kc.ipk
Generating index for package ./iptables-mod-conntrack-extra_1.8.7-1_mipsel_24kc.ipk
Generating index for package ./iptables-mod-extra_1.8.7-1_mipsel_24kc.ipk
……
Generating index for package ./wget-ssl_1.21.2-1_mipsel_24kc.ipk
Generating index for package ./zerotier_1.10.1-1_mipsel_24kc.ipk
Signing package index...
make[2]: Leaving directory '/home/by/lede'
export MAKEFLAGS= ;make -w -r json_overview_image_info
make[2]: Entering directory '/home/by/lede'
make[2]: Nothing to be done for 'json_overview_image_info'.
make[2]: Leaving directory '/home/by/lede'
export MAKEFLAGS= ;make -w -r checksum
make[2]: Entering directory '/home/by/lede'
make[2]: Leaving directory '/home/by/lede'
make[1]: Leaving directory '/home/by/lede'
miaoermua commented 1 year ago

有解决方法,在编译该版时按照默认的配置编译一遍将此时的 initramfs-kernel.bin 下下来,再继续编译 squashfs-sysupgrade.bin