diff --git a/cmake/Findclang.cmake b/cmake/Findclang.cmake index c556455d1c..5f5bef8207 100644 --- a/cmake/Findclang.cmake +++ b/cmake/Findclang.cmake @@ -48,7 +48,9 @@ else() /c/msys64/mingw64/lib c:\\msys64\\mingw64\\lib ) - set(CLANG_LIBRARIES ${CLANG_LIBRARIES} ${CLANG_${_prettylibname_}_LIB}) + if(CLANG_${_prettylibname_}_LIB) + set(CLANG_LIBRARIES ${CLANG_LIBRARIES} ${CLANG_${_prettylibname_}_LIB}) + endif() endmacro(FIND_AND_ADD_CLANG_LIB) FIND_AND_ADD_CLANG_LIB(clangFrontendTool)