Skip to content

Commit f103d46

Browse files
authored
[Merge][Comgr] Comgr LIT support (llvm#1136)
Two dependent changes needed for CI jobs to run Comgr LIT
2 parents ea7c052 + 005e2e4 commit f103d46

File tree

1 file changed

+9
-6
lines changed

1 file changed

+9
-6
lines changed

amd/comgr/test-lit/CMakeLists.txt

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,16 @@ cannonicalize_cmake_boolean(COMGR_DISABLE_SPIRV)
1010

1111
configure_file(lit.site.cfg.py.in lit.site.cfg.py @ONLY)
1212

13-
# Comgr source build
14-
if (EXISTS "${LLVM_TOOLS_BINARY_DIR}/../../bin/llvm-lit")
15-
set(LLVM_LIT_PATH "${LLVM_TOOLS_BINARY_DIR}/../../bin/llvm-lit")
16-
# LLVM external projects build
17-
else()
18-
set(LLVM_LIT_PATH "${LLVM_TOOLS_BINARY_DIR}/llvm-lit")
13+
if (NOT DEFINED LLVM_LIT_PATH)
14+
# Comgr source build
15+
if (EXISTS "${LLVM_TOOLS_BINARY_DIR}/../../bin/llvm-lit")
16+
set(LLVM_LIT_PATH "${LLVM_TOOLS_BINARY_DIR}/../../bin/llvm-lit")
17+
# LLVM external projects build
18+
else()
19+
set(LLVM_LIT_PATH "${LLVM_TOOLS_BINARY_DIR}/llvm-lit")
20+
endif()
1921
endif()
22+
message("--LLVM_LIT_PATH: ${LLVM_LIT_PATH}")
2023

2124
add_custom_target(test-lit COMMAND "${LLVM_LIT_PATH}"
2225
"${CMAKE_CURRENT_BINARY_DIR}" -v)

0 commit comments

Comments
 (0)