Index: cmake/modules/AddLLVM.cmake =================================================================== --- cmake/modules/AddLLVM.cmake +++ cmake/modules/AddLLVM.cmake @@ -263,14 +263,14 @@ # function(add_windows_version_resource_file OUT_VAR) set(sources ${ARGN}) - if (MSVC) + if (MSVC AND CMAKE_HOST_SYSTEM_NAME STREQUAL "Windows") set(resource_file ${LLVM_SOURCE_DIR}/resources/windows_version_resource.rc) if(EXISTS ${resource_file}) set(sources ${sources} ${resource_file}) source_group("Resource Files" ${resource_file}) set(windows_resource_file ${resource_file} PARENT_SCOPE) endif() - endif(MSVC) + endif(MSVC AND CMAKE_HOST_SYSTEM_NAME STREQUAL "Windows") set(${OUT_VAR} ${sources} PARENT_SCOPE) endfunction(add_windows_version_resource_file)