Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

[BUILD] Enable optional standalone spirv-tools #1275

Closed
doctaweeks opened this issue Jun 13, 2018 · 11 comments
Closed

[BUILD] Enable optional standalone spirv-tools #1275

doctaweeks opened this issue Jun 13, 2018 · 11 comments

Comments

@doctaweeks
Copy link
Contributor

libspirv.h is packaged with spirv-tools: spirv-tools/libspirv.h

@tqchen
Copy link
Member

tqchen commented Jun 13, 2018

hmm, does this change happens in the recent VulkanSDK? Normally files will be copied if you do build tools after you install vulkan sdk

@doctaweeks
Copy link
Contributor Author

This is with spirv-tools 2018.2

@tqchen
Copy link
Member

tqchen commented Jun 13, 2018

The default build assumes the installation of vulkan sdk https://vulkan.lunarg.com/sdk/home, which comes with spirv-tools, and if you run ./build_tools.sh under the sdk root, you should be able to get spirv-tools in the corresponding folder. If you use a standalone spirv-tools, maybe we need to update the CMake search rule to do so

@doctaweeks
Copy link
Contributor Author

I have a standalone spirv-tools. I think updating the search rule would be useful for any distro that packages the vulkan components separately.

@tqchen
Copy link
Member

tqchen commented Jun 13, 2018

sounds reasonable, are you interested in sending a patch?

@tqchen
Copy link
Member

tqchen commented Jun 13, 2018

This likely will involve modification of the following two files

We can introduce an optional option USE_SPRIV and use that info when this is set

@tqchen tqchen changed the title fatal error: vulkan/libspirv.h: No such file or directory [BUILD] Enable optional standalone spirv-tools Jun 13, 2018
@doctaweeks
Copy link
Contributor Author

Rather than an option I think it's fine to check for one, then the other, and just use the one that's found. I suspect it's unlikely for someone to have it installed both ways.

@tqchen
Copy link
Member

tqchen commented Jun 13, 2018

that also works

@tqchen
Copy link
Member

tqchen commented Jun 18, 2018

@doctaweeks any updates on this? would you like to send a patch?

@doctaweeks
Copy link
Contributor Author

I haven't had a chance to revisit this in depth yet.

I can add that a complete fix for this will be a little more complicated. There is a separate pkgconfig file for spirv-tools that should probably be used (currently "find_package(Vulkan").

I'll try to get to it this week.

@tqchen
Copy link
Member

tqchen commented Jun 19, 2018

close by #1298

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

No branches or pull requests

2 participants