我正在为android模拟器编译linux源代码。当我执行make命令(用于构建和交叉编译linux源代码)时,我收到以下错误“pmem.c”文件。
root@ubuntu:~/common# make
CHK include/linux/version.h
CHK include/linux/utsrelease.h
SYMLINK include/asm -> include/asm-x86
CALL scripts/checksyscalls.sh
CHK include/linux/compile.h
CC drivers/misc/pmem.o
drivers/misc/pmem.c:441: error: conflicting types for ‘phys_mem_access_prot’
/home/preetam/common/arch/x86/include/asm/pgtable.h:383: note: previous declaration of ‘phys_mem_access_prot’ was here
drivers/misc/pmem.c: In function ‘flush_pmem_file’:
drivers/misc/pmem.c:805: error: implicit declaration of function ‘dmac_flush_range’
drivers/misc/pmem.c: In function ‘pmem_setup’:
drivers/misc/pmem.c:1265: error: implicit declaration of function ‘ioremap_cached’
drivers/misc/pmem.c:1266: warning: assignment makes pointer from integer without a cast
make[2]: *** [drivers/misc/pmem.o] Error 1
make[1]: *** [drivers/misc] Error 2
make: *** [drivers] Error 2
root@ubuntu:~/common#
如何解决此错误。似乎“pmem.c”文件中可能存在一些问题,我将不得不选择不同的git存储库。但这将是一件非常复杂的事情,因为现在我已经完成了大部分工作。我可能要看到这个文件的正确版本。请有人告诉我该怎么做?
如何解决这个错误。
请帮助..谢谢!
答案 0 :(得分:2)
您粘贴的消息中存在多个错误,包括冲突类型和隐式声明。您可能需要验证的三件事: