-
Notifications
You must be signed in to change notification settings - Fork 14.3k
[HLSL][CMake] Add clangd and distribution settings #92011
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
Conversation
This just adds some simple distribution settings and includes clangd in the build for distribution.
@llvm/pr-subscribers-clang Author: Chris B (llvm-beanz) ChangesThis just adds some simple distribution settings and includes clangd in the build for distribution. Full diff: https://github.com/llvm/llvm-project/pull/92011.diff 1 Files Affected:
diff --git a/clang/cmake/caches/HLSL.cmake b/clang/cmake/caches/HLSL.cmake
index 84850c86f12cd..9aa28625ab81e 100644
--- a/clang/cmake/caches/HLSL.cmake
+++ b/clang/cmake/caches/HLSL.cmake
@@ -8,6 +8,10 @@ set(LLVM_EXPERIMENTAL_TARGETS_TO_BUILD "DirectX;SPIRV" CACHE STRING "")
# HLSL support is currently limted to clang, eventually it will expand to
# clang-tools-extra too.
-set(LLVM_ENABLE_PROJECTS "clang" CACHE STRING "")
+set(LLVM_ENABLE_PROJECTS "clang;clang-tools-extra" CACHE STRING "")
set(CLANG_ENABLE_HLSL On CACHE BOOL "")
+
+set(LLVM_DISTRIBUTION_COMPONENTS
+ "clang;hlsl-resource-headers;clangd"
+ CACHE STRING "")
|
@llvm/pr-subscribers-hlsl Author: Chris B (llvm-beanz) ChangesThis just adds some simple distribution settings and includes clangd in the build for distribution. Full diff: https://github.com/llvm/llvm-project/pull/92011.diff 1 Files Affected:
diff --git a/clang/cmake/caches/HLSL.cmake b/clang/cmake/caches/HLSL.cmake
index 84850c86f12cd..9aa28625ab81e 100644
--- a/clang/cmake/caches/HLSL.cmake
+++ b/clang/cmake/caches/HLSL.cmake
@@ -8,6 +8,10 @@ set(LLVM_EXPERIMENTAL_TARGETS_TO_BUILD "DirectX;SPIRV" CACHE STRING "")
# HLSL support is currently limted to clang, eventually it will expand to
# clang-tools-extra too.
-set(LLVM_ENABLE_PROJECTS "clang" CACHE STRING "")
+set(LLVM_ENABLE_PROJECTS "clang;clang-tools-extra" CACHE STRING "")
set(CLANG_ENABLE_HLSL On CACHE BOOL "")
+
+set(LLVM_DISTRIBUTION_COMPONENTS
+ "clang;hlsl-resource-headers;clangd"
+ CACHE STRING "")
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Including clang-tools-extra makes sense to me. Setting up the distribution may not be as universal but it seems fine too as a default in this cache file.
LGTM
if (NOT CMAKE_CONFIGURATION_TYPES) | ||
set(LLVM_DISTRIBUTION_COMPONENTS | ||
"clang;hlsl-resource-headers;clangd" | ||
CACHE STRING "") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we're going to define a distribution components we might want clang-dxc
in there as well
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The clang symlinks are all part of the clang
component, so they all get installed together. We should probably change that and have some which are part of the default target (clang, clang++), and others that aren't (like clang-dxc).
This just adds some simple distribution settings and includes clangd in the build for distribution.