This is an archive of the discontinued LLVM Phabricator instance.

libclc: fix linking against libLLVMSupport
AcceptedPublic

Authored by illwieckz on May 18 2023, 7:46 AM.

Details

Reviewers
tstellar
nikic
Summary

Fixes:

[1/22] Linking CXX executable prepare_builtins
FAILED: prepare_builtins
: && /usr/bin/c++ -fno-lto -O3 -DNDEBUG -fno-lto     -Wl,-rpath-link,  -Wl,--gc-sections CMakeFiles/prepare_builtins.dir/utils/prepare-builtins.cpp.o -o prepare_builtins  -Wl,-rpath,"\$ORIGIN/../lib"  prefix/lib/libLLVMBitWriter.so.17git  prefix/lib/libLLVMBitReader.so.17git  prefix/lib/libLLVMCore.so.17git && :
/usr/bin/ld: CMakeFiles/prepare_builtins.dir/utils/prepare-builtins.cpp.o: undefined reference to symbol '_ZN4llvm2cl6Option11addArgumentEv'

Diff Detail

Event Timeline

illwieckz created this revision.May 18 2023, 7:46 AM
Herald added a project: Restricted Project. · View Herald TranscriptMay 18 2023, 7:46 AM
Herald added a subscriber: jvesely. · View Herald Transcript
illwieckz requested review of this revision.May 18 2023, 7:46 AM
Herald added a project: Restricted Project. · View Herald TranscriptMay 18 2023, 7:46 AM
illwieckz added a comment.EditedMay 18 2023, 7:51 AM

I don't know when the regression happened, but 16.0.0 and current main (f56a738) are known to be affected. I assume it happened between 15 and 16 (I built some llvm 15 before without problem).

This fixes:

illwieckz edited the summary of this revision. (Show Details)May 18 2023, 7:52 AM
illwieckz updated this revision to Diff 523387.May 18 2023, 8:02 AM

I sorted alphabetically the libraries to be linked with.

illwieckz edited the summary of this revision. (Show Details)May 18 2023, 9:08 AM
nikic accepted this revision.May 18 2023, 9:13 AM
nikic added a subscriber: nikic.

LGTM. If you need me to commit this for you, can you please share the Name <email> to use?

This revision is now accepted and ready to land.May 18 2023, 9:13 AM

LGTM. If you need me to commit this for you, can you please share the Name <email> to use?

Thomas Debesse <dev@illwieckz.net>