> make[1]: Entering directory '/home/openwrt/src/BPI-R4-bsp-5.4/linux-mt'
CC [M] /home/openwrt/src/BPI-R4-bsp-5.4/wifi-mt7996e/mt76-2023-12-18-bebd9cff/mmio.o
CC [M] /home/openwrt/src/BPI-R4-bsp-5.4/wifi-mt7996e/mt76-2023-12-18-bebd9cff/util.o
CC [M] /home/openwrt/src/BPI-R4-bsp-5.4/wifi-mt7996e/mt76-2023-12-18-bebd9cff/trace.o
CC [M] /home/openwrt/src/BPI-R4-bsp-5.4/wifi-mt7996e/mt76-2023-12-18-bebd9cff/dma.o
CC [M] /home/openwrt/src/BPI-R4-bsp-5.4/wifi-mt7996e/mt76-2023-12-18-bebd9cff/mt7996/pci.o
CC [M] /home/openwrt/src/BPI-R4-bsp-5.4/wifi-mt7996e/mt76-2023-12-18-bebd9cff/mac80211.o
CC [M] /home/openwrt/src/BPI-R4-bsp-5.4/wifi-mt7996e/mt76-2023-12-18-bebd9cff/debugfs.o
CC [M] /home/openwrt/src/BPI-R4-bsp-5.4/wifi-mt7996e/mt76-2023-12-18-bebd9cff/mt7996/init.o
In file included from /home/openwrt/src/BPI-R4-bsp-5.4/wifi-mt7996e/backports-6.5/backport-include/linux/kernel.h:3,
from /home/openwrt/src/BPI-R4-bsp-5.4/wifi-mt7996e/mt76-2023-12-18-bebd9cff/mt76.h:9,
from /home/openwrt/src/BPI-R4-bsp-5.4/wifi-mt7996e/mt76-2023-12-18-bebd9cff/mmio.c:6:
./include/linux/kernel.h:6:10: fatal error: stdarg.h: No such file or directory
我使用这里的代码编译U-Boot失败,但是编译Kernel成功了。错误如下
> make -C u-boot-mt O=build_sdmmc mt7988a_bananapi_bpi-r4-sdmmc_config CROSS_COMPILE=/opt/FriendlyARM/toolchain/11.3-aarch64/bin/aarch64-linux-gnu- -j12
make[1]: Entering directory '/home/openwrt/src/BPI-R4-bsp-6.1/u-boot-mt'
make[2]: Entering directory '/home/openwrt/src/BPI-R4-bsp-6.1/u-boot-mt/build_sdmmc'
GEN Makefile
arch/../configs/mt7988a_bananapi_bpi-r4-sdmmc_defconfig:163:warning: override: reassigning to symbol PINCTRL_MT7988
#
# configuration written to .config
#
make[2]: Leaving directory '/home/openwrt/src/BPI-R4-bsp-6.1/u-boot-mt/build_sdmmc'
make[1]: Leaving directory '/home/openwrt/src/BPI-R4-bsp-6.1/u-boot-mt'
make -C u-boot-mt O=build_sdmmc CROSS_COMPILE=/opt/FriendlyARM/toolchain/11.3-aarch64/bin/aarch64-linux-gnu- -j12 LOCALVERSION="-BPI-R4-r24894-4d30d371e7" PKG_CONFIG_EXTRAARGS="--static" V='' u-boot.bin
make[1]: Entering directory '/home/openwrt/src/BPI-R4-bsp-6.1/u-boot-mt'
make[2]: Entering directory '/home/openwrt/src/BPI-R4-bsp-6.1/u-boot-mt/build_sdmmc'
GEN Makefile
scripts/kconfig/conf --syncconfig Kconfig
CFG u-boot.cfg
GEN include/autoconf.mk.dep
GEN include/autoconf.mk
GEN Makefile
UPD include/generated/timestamp_autogenerated.h
ENVC include/generated/env.txt
Using .. as source for U-Boot
.. is not clean, please run 'make mrproper'
in the '..' directory.
make[2]: *** [/home/openwrt/src/BPI-R4-bsp-6.1/u-boot-mt/Makefile:1891: prepare3] Error 1
make[2]: Leaving directory '/home/openwrt/src/BPI-R4-bsp-6.1/u-boot-mt/build_sdmmc'
make[1]: *** [Makefile:177: sub-make] Error 2
make[1]: Leaving directory '/home/openwrt/src/BPI-R4-bsp-6.1/u-boot-mt'
make: *** [Makefile:56: u-boot_sdmmc] Error 2
I used the code here to compile U-Boot successfully, but failed to compile the kernel (wifi-mt7996e driver).The error is as follows:
make[1]: Entering directory '/home/openwrt/src/BPI-R4-bsp-5.4/linux-mt'
CC [M] /home/openwrt/src/BPI-R4-bsp-5.4/wifi-mt7996e/mt76-2023-12-18-bebd9cff/mmio.o
CC [M] /home/openwrt/src/BPI-R4-bsp-5.4/wifi-mt7996e/mt76-2023-12-18-bebd9cff/util.o
CC [M] /home/openwrt/src/BPI-R4-bsp-5.4/wifi-mt7996e/mt76-2023-12-18-bebd9cff/trace.o
CC [M] /home/openwrt/src/BPI-R4-bsp-5.4/wifi-mt7996e/mt76-2023-12-18-bebd9cff/dma.o
CC [M] /home/openwrt/src/BPI-R4-bsp-5.4/wifi-mt7996e/mt76-2023-12-18-bebd9cff/mt7996/pci.o
CC [M] /home/openwrt/src/BPI-R4-bsp-5.4/wifi-mt7996e/mt76-2023-12-18-bebd9cff/mac80211.o
CC [M] /home/openwrt/src/BPI-R4-bsp-5.4/wifi-mt7996e/mt76-2023-12-18-bebd9cff/debugfs.o
CC [M] /home/openwrt/src/BPI-R4-bsp-5.4/wifi-mt7996e/mt76-2023-12-18-bebd9cff/mt7996/init.o
In file included from /home/openwrt/src/BPI-R4-bsp-5.4/wifi-mt7996e/backports-6.5/backport-include/linux/kernel.h:3,
from /home/openwrt/src/BPI-R4-bsp-5.4/wifi-mt7996e/mt76-2023-12-18-bebd9cff/mt76.h:9,
from /home/openwrt/src/BPI-R4-bsp-5.4/wifi-mt7996e/mt76-2023-12-18-bebd9cff/mmio.c:6:
./include/linux/kernel.h:6:10: fatal error: stdarg.h: No such file or directory
I used the code here to compile U-Boot failed, but compiled the kernel successfully.
make -C u-boot-mt O=build_sdmmc mt7988a_bananapi_bpi-r4-sdmmc_config CROSS_COMPILE=/opt/FriendlyARM/toolchain/11.3-aarch64/bin/aarch64-linux-gnu- -j12
make[1]: Entering directory '/home/openwrt/src/BPI-R4-bsp-6.1/u-boot-mt'
make[2]: Entering directory '/home/openwrt/src/BPI-R4-bsp-6.1/u-boot-mt/build_sdmmc'
GEN Makefile
arch/../configs/mt7988a_bananapi_bpi-r4-sdmmc_defconfig:163:warning: override: reassigning to symbol PINCTRL_MT7988
#
# configuration written to .config
#
make[2]: Leaving directory '/home/openwrt/src/BPI-R4-bsp-6.1/u-boot-mt/build_sdmmc'
make[1]: Leaving directory '/home/openwrt/src/BPI-R4-bsp-6.1/u-boot-mt'
make -C u-boot-mt O=build_sdmmc CROSS_COMPILE=/opt/FriendlyARM/toolchain/11.3-aarch64/bin/aarch64-linux-gnu- -j12 LOCALVERSION="-BPI-R4-r24894-4d30d371e7" PKG_CONFIG_EXTRAARGS="--static" V='' u-boot.bin
make[1]: Entering directory '/home/openwrt/src/BPI-R4-bsp-6.1/u-boot-mt'
make[2]: Entering directory '/home/openwrt/src/BPI-R4-bsp-6.1/u-boot-mt/build_sdmmc'
GEN Makefile
scripts/kconfig/conf --syncconfig Kconfig
CFG u-boot.cfg
GEN include/autoconf.mk.dep
GEN include/autoconf.mk
GEN Makefile
UPD include/generated/timestamp_autogenerated.h
ENVC include/generated/env.txt
Using .. as source for U-Boot
.. is not clean, please run 'make mrproper'
in the '..' directory.
make[2]: *** [/home/openwrt/src/BPI-R4-bsp-6.1/u-boot-mt/Makefile:1891: prepare3] Error 1
make[2]: Leaving directory '/home/openwrt/src/BPI-R4-bsp-6.1/u-boot-mt/build_sdmmc'
make[1]: *** [Makefile:177: sub-make] Error 2
make[1]: Leaving directory '/home/openwrt/src/BPI-R4-bsp-6.1/u-boot-mt'
make: *** [Makefile:56: u-boot_sdmmc] Error 2
Build failed!
After U-Boot is successfully compiled, two uboot images will be generated: u-boot-mt/build_emmc/u-boot.bin and u-boot-mt/build_sdmmc/u-boot.bin. How can I flash u-boot.bin to nand flash? In addition, how can the u-boot in bsp 6.1 and the kernel in bsp 5.4 be compiled successfully?
This 6.1 bsp does not seem to have wifi driver support?
Also, will the damage of u-boot in nand flash affect the sd card boot function?