[all-commits] [llvm/llvm-project] 2fbfbf: [cmake] Resolve symlink when finding install prefi...

Nikita Popov via All-commits all-commits at lists.llvm.org
Tue Mar 18 06:49:01 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 2fbfbf499eabb84024541060c61f0d88e882c167
      https://github.com/llvm/llvm-project/commit/2fbfbf499eabb84024541060c61f0d88e882c167
  Author: Nikita Popov <npopov at redhat.com>
  Date:   2025-03-18 (Tue, 18 Mar 2025)

  Changed paths:
    M cmake/Modules/FindPrefixFromConfig.cmake

  Log Message:
  -----------
  [cmake] Resolve symlink when finding install prefix (#124743)

When determining the install prefix in LLVMConfig.cmake etc resolve
symlinks in CMAKE_CURRENT_LIST_FILE first. The motivation for this is to
support symlinks like `/usr/lib64/cmake/llvm` to
`/usr/lib64/llvm19/lib/cmake/llvm`. This only works correctly if the
paths are relative to the resolved symlink.

It's worth noting that this *mostly* already works out of the box,
because cmake automatically does the symlink resolution when the library
is found via CMAKE_PREFIX_PATH. It just doesn't happen when it's found
via the default prefix path.



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