gpt4 book ai didi

android - smd_private.h : No such file or directory

转载 作者:行者123 更新时间:2023-11-30 17:05:10 26 4
gpt4 key购买 nike

我正在尝试构建一个独立的 Android 内核,并且想编写可加载内核模块,但是当我构建 module.c 文件时,出现此错误

error: smd_private.h: No such file or directory

谷歌搜索告诉我我应该改变<smd_private.h>进入"smd_private.h" .但是错误仍然存​​在!你能帮我吗?

最佳答案

检查以确保 smd_private.h 与我的 module.c 位于同一目录中

这是来自 https://gcc.gnu.org/onlinedocs/cpp/Include-Syntax.html#Include-Syntax 的信息

2.1 Include Syntax
Both user and system header files are included using the preprocessing
directive ‘#include’. It has two variants:

#include <file>
This variant is used for system header files. It searches for a file
named file in a standard list of system directories. You can prepend
directories to this list with the -I option (see Invocation).

#include "file"
This variant is used for header files of your own program. It searches
for a file named file first in the directory containing the current
file, then in the quote directories and then the same directories used
for <file>. You can prepend directories to the list of quote directories
with the -iquote option.

The argument of ‘#include’, whether delimited with quote marks or angle
brackets, behaves like a string constant in that comments are not
recognized, and macro names are not expanded. Thus, #include <x/*y>
specifies inclusion of a system header file named x/*y.

However, if backslashes occur within file, they are considered ordinary
text characters, not escape characters. None of the character escape
sequences appropriate to string constants in C are processed.
Thus, #include "x\n\\y" specifies a filename containing three
backslashes. (Some systems interpret ‘\’ as a pathname separator.
All of these also interpret ‘/’ the same way. It is most portable to
use only ‘/’.)

It is an error if there is anything (other than comments) on the line
after the file name.

关于android - smd_private.h : No such file or directory,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/35423290/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com