[all-commits] [llvm/llvm-project] 5e5f15: cmake: Gate host library targets on shared library...
Matt Arsenault via All-commits
all-commits at lists.llvm.org
Thu Jul 9 06:01:42 PDT 2026
Branch: refs/heads/users/arsenm/runtimes-fix-cross-compile-host-library-targets
Home: https://github.com/llvm/llvm-project
Commit: 5e5f15358360ab112aae4e787feab88461dfa781
https://github.com/llvm/llvm-project/commit/5e5f15358360ab112aae4e787feab88461dfa781
Author: Matt Arsenault <Matthew.Arsenault at amd.com>
Date: 2026-07-09 (Thu, 09 Jul 2026)
Changed paths:
M clang/cmake/modules/ClangConfig.cmake.in
M llvm/cmake/modules/LLVMConfig.cmake.in
Log Message:
-----------
cmake: Gate host library targets on shared library support
This avoids cmake warnings about importing unsupported shared libraries (which
are also host build artifacts) when building libc for amdgpu.
00b2f81 guarded exported library targets and host find_package() calls behind
"if(NOT CMAKE_CROSSCOMPILING)". The intent was to avoid importing the always-shared
targets (LTO, Remarks) on targets which will warn due to not supportind shared
libraries. However CMAKE_CROSSCOMPILING is too broad since it is also set for
usable cross-built libraries.
Change to check if the consuming platform supports shared libraries instead. This
feels not quite precise though, since the found libraries could still be static.
Co-authored-by: Claude (Opus 4.8) <noreply at anthropic.com>
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list