diff options
author | Stephen Neuendorffer <stephen.neuendorffer@amd.com> | 2023-03-10 21:52:26 -0800 |
---|---|---|
committer | Stephen Neuendorffer <stephen.neuendorffer@amd.com> | 2023-03-11 09:15:06 -0800 |
commit | 1ab46e5cf86c3799044b1c6a52a4f4b8a5280c09 (patch) | |
tree | 27f50b259d1a8f01e6b44764b431c1c3d9e5a727 /libc/utils | |
parent | b1fdcd5fbc09f9f3e1c8a8b954aa8f9067401b31 (diff) | |
download | llvm-1ab46e5cf86c3799044b1c6a52a4f4b8a5280c09.tar.gz |
[libc] update LibcTableGenUtil for LLVM_LINK_LLVM_DYLIB
This library is linked into libc-hdrgen, which is compiled with
DISABLE_LLVM_LINK_LLVM_DYLIB. This option avoids linking with
libLLVM.so when LLVM_LINK_LLVM_DYLIB is specified. Unfortunately,
this can cause wierd linkage errors where symbols are defined
multiple times, with one definition coming from static linkage
and another definition coming from libLLVM.so. This is usually
apparent as a link error with options defined multiple times.
This patch adds DISABLE_LLVM_LINK_LLVM_DYLIB to this library, to
get consistent linkage of libc-hdrgen.
Differential Revision: https://reviews.llvm.org/D145839
Diffstat (limited to 'libc/utils')
-rw-r--r-- | libc/utils/LibcTableGenUtil/CMakeLists.txt | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/libc/utils/LibcTableGenUtil/CMakeLists.txt b/libc/utils/LibcTableGenUtil/CMakeLists.txt index d2632a240bd3..222f177ee2f7 100644 --- a/libc/utils/LibcTableGenUtil/CMakeLists.txt +++ b/libc/utils/LibcTableGenUtil/CMakeLists.txt @@ -2,6 +2,7 @@ add_llvm_library( LibcTableGenUtil APIIndexer.cpp APIIndexer.h + DISABLE_LLVM_LINK_LLVM_DYLIB LINK_COMPONENTS Support TableGen ) target_include_directories(LibcTableGenUtil PUBLIC ${LIBC_SOURCE_DIR}) |