This fixes cross-compilation when targeting a platform not using libdl and mirrors libdl linking in other parts of the code.
Details
Details
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Comment Actions
I think this is ok, but adding @beanz who knows the cmake conventions better than me.
Comment Actions
FYI as reported on IRC, this likely breaks standalone build of clang
<mceier> standalone builds of clang are still supported right ? commit 0073c293a401774ac96b4b3d27f05e13f379f98e seems to break them, since HAVE_LIBDL is not defined (it requires config-ix include from llvm) causing linking libclang.so to fail with undefined reference to dladdr due to missing -ldl <LebedevRI> assuming the versions match, sounds like a bug <mceier> LebedevRI: by adding "-DHAVE_LIBDL -DCMAKE_DL_LIBS=dl" to cmake I was able to build standalone clang; so it is a bug
Would be good to either have a fix or a revert.