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

Fix build error when SLANG_ENABLE_TESTS is set to OFF #6420

Conversation

jkwak-work
Copy link
Collaborator

When SLANG_ENABLE_TESTS is disabled but SLANG_ENABLE_GFX is enabled, cmake was failing. It turned out that gfx build target was trying to copy some of files to the directory where slang-test uses. When SLANG_ENABLE_TESTS is disabled, the directory information became unavailable, because slang-test target became unavailable.

This commit makes the copying behavior conditional on SLANG_ENABLE_TESTS in the gfx build target.

Closes #6036

This PR is mostly done by github Copilot.

When SLANG_ENABLE_TESTS is disabled but SLANG_ENABLE_GFX is enabled,
cmake was failing. It turned out that gfx build target was trying to
copy some of files to the directory where slang-test uses. When
SLANG_ENABLE_TESTS is disabled, the directory information became
unavailable, because slang-test target became unavailable.

This commit makes the copying behavior conditional on SLANG_ENABLE_TESTS
in the gfx build target.
@jkwak-work jkwak-work added the pr: non-breaking PRs without breaking changes label Feb 21, 2025
@jkwak-work jkwak-work self-assigned this Feb 21, 2025
@jkwak-work jkwak-work requested a review from a team as a code owner February 21, 2025 15:05
@jkwak-work
Copy link
Collaborator Author

/format

@slangbot
Copy link
Contributor

🌈 Formatted, please merge the changes from this PR

slangbot and others added 3 commits February 21, 2025 18:32
Co-authored-by: slangbot <186143334+slangbot@users.noreply.github.com>
@jkwak-work
Copy link
Collaborator Author

@expipiplus1 , did you have a chance to review this yet?

@expipiplus1 expipiplus1 enabled auto-merge (squash) February 24, 2025 23:49
@expipiplus1 expipiplus1 merged commit bca772c into shader-slang:master Feb 28, 2025
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr: non-breaking PRs without breaking changes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

SLANG_ENABLE_TESTS option is not working
3 participants