Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

[Language Server] -I dir flag does not work on some systems #33

Closed
Galarius opened this issue Oct 5, 2021 · 2 comments
Closed

[Language Server] -I dir flag does not work on some systems #33

Galarius opened this issue Oct 5, 2021 · 2 comments

Comments

@Galarius
Copy link
Owner

Galarius commented Oct 5, 2021

Passing -I dir to clBuildProgram does not guarantee that the header will be included. Logs:

21:59:08:348 DBG BuildSource:183 #diagnostics Building program with options: -I /Users/user/project/kernel
21:59:08:348 TRE Get:268 #diagnostics BuildLog:
<program source>:7:10: fatal error: 'inc.h' file not found
#include "inc.h"
         ^
@Galarius
Copy link
Owner Author

Galarius commented Oct 5, 2021

According to https://www.khronos.org/registry/OpenCL/specs/2.2/html/OpenCL_API.html#compiler-options:

-I dir
Add the directory dir to the list of directories to be searched for header files. dir can optionally be enclosed in double quotes.
This option is not portable due to its dependency on host file system and host operating system. It is supported for backwards compatibility with previous OpenCL versions. Developers are encouraged to create and use explicit header objects by means of clCompileProgram followed by clLinkProgram.

@Galarius
Copy link
Owner Author

-I option removed.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant