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

Align git-sync-deps and CMake to use external/spirv-headers by default #4963

Merged
merged 1 commit into from
Jan 24, 2023

Conversation

kpet
Copy link
Contributor

@kpet kpet commented Oct 7, 2022

Align git-sync-deps and CMake to use external/SPIRV-Headers by default

This should help with avoiding mistakes such as the one that happened under #4958.

Signed-off-by: Kevin Petit kevin.petit@arm.com
Change-Id: I922f02e25c507f3412e0e7a99f525fb617b2d426

@Keenuts
Copy link
Contributor

Keenuts commented Oct 27, 2022

Not against changing the order, but what about just not looking for SPIRV-Headers? the README way is to use the DEPS, meaning path should be in lowercase. If people want to have their tree in another path, they can define SPIRV-Headers_SOURCE_DIR no? (maybe renaming it to something easier to use would be nice)

@Keenuts Keenuts self-assigned this Oct 27, 2022
external/CMakeLists.txt Outdated Show resolved Hide resolved
@kpet
Copy link
Contributor Author

kpet commented Oct 27, 2022

Not against changing the order, but what about just not looking for SPIRV-Headers?

That works for me and is cleaner. I kept it as I assumed it was used by someone (the CI at least :)).

they can define SPIRV-Headers_SOURCE_DIR no? (maybe renaming it to something easier to use would be nice)

I would advise against renaming that variable. I know of several projects that make use of it.

@Keenuts
Copy link
Contributor

Keenuts commented Oct 27, 2022

Not against changing the order, but what about just not looking for SPIRV-Headers?

That works for me and is cleaner. I kept it as I assumed it was used by someone (the CI at least :)).

they can define SPIRV-Headers_SOURCE_DIR no? (maybe renaming it to something easier to use would be nice)

I would advise against renaming that variable. I know of several projects that make use of it.

@dneto0 do you know if that's still used?

@kpet
Copy link
Contributor Author

kpet commented Oct 27, 2022

Taking a step back I'm wondering whether it would make sense to align everything on SPIRV-Headers since that's what the folder will be named after a manual clone on OSes that have case-sensitive file names. Is the name used by git-sync-deps different by design?

@Keenuts
Copy link
Contributor

Keenuts commented Oct 27, 2022

Taking a step back I'm wondering whether it would make sense to align everything on SPIRV-Headers since that's what the folder will be named after a manual clone on OSes that have case-sensitive file names. Is the name used by git-sync-deps different by design?

If that's not by design, I would also be in favor of keeping SPIRV-Headers

@kpet
Copy link
Contributor Author

kpet commented Oct 27, 2022

Alright, I'll do that then.

@kpet kpet force-pushed the default-headers-path-search-order branch from 051a7a0 to 49a8d2a Compare October 27, 2022 12:58
@kpet kpet changed the title Change the search order for the default paths to the SPIRV-Headers Align git-sync-deps and CMake to use external/SPIRV-Headers by default Oct 27, 2022
@Keenuts
Copy link
Contributor

Keenuts commented Oct 28, 2022

Thanks! You'll have to fix the CI scripts too (some don't use the DEPS file), like kokoro/scripts/linux/build-docker.sh

@dneto0
Copy link
Collaborator

dneto0 commented Dec 16, 2022

Not against changing the order, but what about just not looking for SPIRV-Headers?

That works for me and is cleaner. I kept it as I assumed it was used by someone (the CI at least :)).

they can define SPIRV-Headers_SOURCE_DIR no? (maybe renaming it to something easier to use would be nice)

I would advise against renaming that variable. I know of several projects that make use of it.

@dneto0 do you know if that's still used?

Sorry for the very late reply. That's used by shaderc and amber. I think vkb does it too (but vkb is dormant).

All this was made when CMake was at version 2.8.12. There may be better mechanisms now.

But also people have strong preferences for naming directories lower-case. That's the case for Chromium IIRC.

Copy link
Collaborator

@s-perron s-perron left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not the direction we want to go. We discussed internally, and we should change the CMAKE file to only look for spirv-header, to match the existing git-sync-deps.

This should help with avoiding mistakes such as the one that happened under KhronosGroup#4958.

Signed-off-by: Kevin Petit <kevin.petit@arm.com>
Change-Id: I922f02e25c507f3412e0e7a99f525fb617b2d426
@kpet kpet force-pushed the default-headers-path-search-order branch from 49a8d2a to e1bdc4d Compare January 24, 2023 16:49
@kpet kpet changed the title Align git-sync-deps and CMake to use external/SPIRV-Headers by default Align git-sync-deps and CMake to use external/spirv-Headers by default Jan 24, 2023
@kpet kpet changed the title Align git-sync-deps and CMake to use external/spirv-Headers by default Align git-sync-deps and CMake to use external/spirv-headers by default Jan 24, 2023
@s-perron s-perron dismissed Keenuts’s stale review January 24, 2023 17:26

The review is stale.

@s-perron
Copy link
Collaborator

The smoke test failures are not related to this change.

@s-perron s-perron merged commit 57fb3c7 into KhronosGroup:main Jan 24, 2023
@kpet kpet deleted the default-headers-path-search-order branch January 24, 2023 20:12
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

Successfully merging this pull request may close these issues.

4 participants