[PATCH] D106703: [libunwind] adds a way to synthesise libgcc

Eli Friedman via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jul 23 17:22:03 PDT 2021


efriedma added a comment.

In D106703#2901842 <https://reviews.llvm.org/D106703#2901842>, @efriedma wrote:

> Oh, wait, I am missing something: you're installing a symlink, and dlopen determines whether a shared library is the same based on inode, not the path.  So I guess this works out in its current form.

Err, no, that's not right; the CMake steps in the patch create a symlink in the build directory, then install() copies the whole library to the install directory, so it isn't symlinked anymore.

In D106703#2901831 <https://reviews.llvm.org/D106703#2901831>, @cjdb wrote:

> Having said that, processes needn't explicitly link with libunwind when their system vends using this setup because libgcc_s.so is libunwind.so, and so even if my understanding about how shared objects are loaded is wrong, the problem should be avoided nonetheless.

If nothing actually links to the library named libunwind.so, why install a library with that name?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D106703/new/

https://reviews.llvm.org/D106703



More information about the llvm-commits mailing list