[all-commits] [llvm/llvm-project] b81689: [LLVM] Fix GetErrcMessages.cmake module for WoA

Omair Javaid via All-commits all-commits at lists.llvm.org
Wed Sep 28 02:41:49 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: b816895b0efc8f13138301d0a981a13d5fb86854
      https://github.com/llvm/llvm-project/commit/b816895b0efc8f13138301d0a981a13d5fb86854
  Author: Muhammad Omair Javaid <omair.javaid at linaro.org>
  Date:   2022-09-28 (Wed, 28 Sep 2022)

  Changed paths:
    M llvm/CMakeLists.txt

  Log Message:
  -----------
  [LLVM] Fix GetErrcMessages.cmake module for WoA

GetErrcMessages.cmake module makes use of cmake's try_run which by
default builds its sources in debug mode unless configured with
CMAKE_TRY_COMPILE_CONFIGURATION. Debug builds on Windows sometimes fail
when appropraite DLLs are not included in path. Also on Windows on Arm
machines debug builds sometimes fail to link the correct debug DLLs.

To fix this I am setting CMAKE_TRY_COMPILE_CONFIGURATION to active build
configuration of currently configured LLVM project. This makes sure we
select same build type for try_run/try_compile cmake modules as
currently configured LLVM project.

Reviewed By: zero9178

Differential Revision: https://reviews.llvm.org/D133482




More information about the All-commits mailing list