https://github.com/nikic updated https://github.com/llvm/llvm-project/pull/126071
>From 2badb9749472014dc02610a3a511b548bfe8a2ae Mon Sep 17 00:00:00 2001 From: Nikita Popov <npo...@redhat.com> Date: Thu, 6 Feb 2025 14:56:25 +0100 Subject: [PATCH 1/2] [libclc] Allow default path when looking for llvm-spirv This is an external tool, so I don't think there is an expectation that it has to be in the LLVM tools bindir. It may also be in the default system bindir (which is not necessarily the same). --- libclc/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libclc/CMakeLists.txt b/libclc/CMakeLists.txt index ff52153354e0a9c..eaec195640610e7 100644 --- a/libclc/CMakeLists.txt +++ b/libclc/CMakeLists.txt @@ -114,7 +114,7 @@ endforeach() if( TARGET llvm-spirv ) get_host_tool_path( llvm-spirv LLVM_SPIRV llvm-spirv_exe llvm-spirv_target ) else() - find_program( LLVM_SPIRV llvm-spirv PATHS ${LLVM_TOOLS_BINARY_DIR} NO_DEFAULT_PATH ) + find_program( LLVM_SPIRV llvm-spirv PATHS ${LLVM_TOOLS_BINARY_DIR} ) set( llvm-spirv_exe "${LLVM_SPIRV}" ) set( llvm-spirv_target ) endif() >From 2e310c82cd6fd65e3b6f8177937cc6743f73df73 Mon Sep 17 00:00:00 2001 From: Nikita Popov <npo...@redhat.com> Date: Thu, 6 Feb 2025 16:31:41 +0100 Subject: [PATCH 2/2] Use HINTS instead of PATHS --- libclc/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libclc/CMakeLists.txt b/libclc/CMakeLists.txt index eaec195640610e7..8e3f5097ba84a44 100644 --- a/libclc/CMakeLists.txt +++ b/libclc/CMakeLists.txt @@ -114,7 +114,7 @@ endforeach() if( TARGET llvm-spirv ) get_host_tool_path( llvm-spirv LLVM_SPIRV llvm-spirv_exe llvm-spirv_target ) else() - find_program( LLVM_SPIRV llvm-spirv PATHS ${LLVM_TOOLS_BINARY_DIR} ) + find_program( LLVM_SPIRV llvm-spirv HINTS ${LLVM_TOOLS_BINARY_DIR} ) set( llvm-spirv_exe "${LLVM_SPIRV}" ) set( llvm-spirv_target ) endif() _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits