我正在尝试编译Linux kernel module,但是现在 我陷入了错误:
In file included from <command-line>:0:0:
/lineage/kernel/xiaomi/msm8996/include/linux/kconfig.h:4:32: fatal error: generated/autoconf.h: No such file or directory
#include <generated/autoconf.h>
顺便说一句,我可以成功构建内核,并且在/lineage/out/target/product/gemini/obj/KERNEL_OBJ
下找到.config文件
我应该如何解决此错误?
这里是完整日志:
$:/lineage$ make -j4 -C kernel/xiaomi/msm8996 M=../../../vendor/qcom/opensource/wlan/qcacld-2.0 O=../../..//lineage/out/target/product/gemini/obj/KERNEL_OBJ ARCH=arm CROSS_COMPIL
E=arm-eabi- modules WLAN_ROOT=../../../vendor/qcom/opensource/wlan/qcacld-2.0 MODNAME=wlan BOARD_PLATFORM=msm8996 CONFIG_QCA_CLD_WLAN=m WLAN_OPEN_SOURCE=1
make: Entering directory '/lineage/kernel/xiaomi/msm8996'
make[1]: Entering directory '/lineage/lineage/out/target/product/gemini/obj/KERNEL_OBJ'
ERROR: Kernel configuration is invalid.
include/generated/autoconf.h or include/config/auto.conf are missing.
Run 'make oldconfig && make prepare' on kernel src to fix it.
WARNING: Symbol version dump ./Module.symvers
is missing; modules will have no dependencies and modversions.
CC [M] ../../../vendor/qcom/opensource/wlan/qcacld-2.0/CORE/HDD/src/wlan_hdd_assoc.o
CC [M] ../../../vendor/qcom/opensource/wlan/qcacld-2.0/CORE/HDD/src/wlan_hdd_cfg.o
CC [M] ../../../vendor/qcom/opensource/wlan/qcacld-2.0/CORE/HDD/src/wlan_hdd_debugfs.o
CC [M] ../../../vendor/qcom/opensource/wlan/qcacld-2.0/CORE/HDD/src/wlan_hdd_dev_pwr.o
In file included from <command-line>:0:0:
/lineage/kernel/xiaomi/msm8996/include/linux/kconfig.h:4:32: fatal error: generated/autoconf.h: No such file or directory
#include <generated/autoconf.h>
^
In file included from <command-line>:0:0:
/lineage/kernel/xiaomi/msm8996/include/linux/kconfig.h:4:32: fatal error: generated/autoconf.h: No such file or directory
#include <generated/autoconf.h>
^
In file included from <command-line>:0:0:
/lineage/kernel/xiaomi/msm8996/include/linux/kconfig.h:4:32: fatal error: generated/autoconf.h: No such file or directory
#include <generated/autoconf.h>
^
compilation terminated.
compilation terminated.
compilation terminated.
/lineage/kernel/xiaomi/msm8996/scripts/Makefile.build:257: recipe for target '../../../vendor/qcom/opensource/wlan/qcacld-2.0/CORE/HDD/src/wlan_hdd_assoc.o' failed
make[2]: *** [../../../vendor/qcom/opensource/wlan/qcacld-2.0/CORE/HDD/src/wlan_hdd_assoc.o] Error 1
make[2]: *** Waiting for unfinished jobs....
/lineage/kernel/xiaomi/msm8996/scripts/Makefile.build:257: recipe for target '../../../vendor/qcom/opensource/wlan/qcacld-2.0/CORE/HDD/src/wlan_hdd_dev_pwr.o' failed
make[2]: *** [../../../vendor/qcom/opensource/wlan/qcacld-2.0/CORE/HDD/src/wlan_hdd_dev_pwr.o] Error 1
In file included from <command-line>:0:0:
/lineage/kernel/xiaomi/msm8996/include/linux/kconfig.h:4:32: fatal error: generated/autoconf.h: No such file or directory
#include <generated/autoconf.h>
^
compilation terminated.
/lineage/kernel/xiaomi/msm8996/scripts/Makefile.build:257: recipe for target '../../../vendor/qcom/opensource/wlan/qcacld-2.0/CORE/HDD/src/wlan_hdd_cfg.o' failed
make[2]: *** [../../../vendor/qcom/opensource/wlan/qcacld-2.0/CORE/HDD/src/wlan_hdd_cfg.o] Error 1
/lineage/kernel/xiaomi/msm8996/scripts/Makefile.build:257: recipe for target '../../../vendor/qcom/opensource/wlan/qcacld-2.0/CORE/HDD/src/wlan_hdd_debugfs.o' failed
make[2]: *** [../../../vendor/qcom/opensource/wlan/qcacld-2.0/CORE/HDD/src/wlan_hdd_debugfs.o] Error 1
/lineage/kernel/xiaomi/msm8996/Makefile:1386: recipe for target '_module_../../../vendor/qcom/opensource/wlan/qcacld-2.0' failed
make[1]: *** [_module_../../../vendor/qcom/opensource/wlan/qcacld-2.0] Error 2
make[1]: Leaving directory '/lineage/lineage/out/target/product/gemini/obj/KERNEL_OBJ'
Makefile:145: recipe for target 'sub-make' failed
make: *** [sub-make] Error 2
make: Leaving directory '/lineage/kernel/xiaomi/msm8996'
#### make failed to build some targets (2 seconds) ####