Skip to content

Always use self-built clang for pcm compilation #284

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

Merged
merged 1 commit into from
Sep 24, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions cl_headers/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
set(CL_HEADERS_LIB cl_headers)
set(CLANG_COMMAND clang)
set(CLANG_COMMAND $<TARGET_FILE:clang> )
if(LLVM_USE_HOST_TOOLS)
build_native_tool(clang CLANG_COMMAND)
endif()

function(copy_file SRC DST)
add_custom_command(
Expand Down Expand Up @@ -32,7 +35,7 @@ function(create_pcm DST MODULE HEADER OPTS DEPS)
add_custom_command (
OUTPUT ${DST}
MAIN_DEPENDENCY ${MODMAP}
DEPENDS ${HEADER} ${DEPS}
DEPENDS ${HEADER} ${DEPS} ${CLANG_COMMAND}
COMMAND
${CLANG_COMMAND} -cc1 -x cl
-I. -O0 ${OPTS}
Expand Down