[llvm-extract] Don't forget to link to Analysis component
authorRoman Lebedev <lebedev.ri@gmail.com>
Wed, 21 Dec 2022 02:03:31 +0000 (05:03 +0300)
committerRoman Lebedev <lebedev.ri@gmail.com>
Wed, 21 Dec 2022 02:16:50 +0000 (05:16 +0300)
commitb2abbd1d0e3ba9a0f313926b3fbf968882553371
tree5b729f6a3a043fece511a945cfa9f09ec5792280
parent3b0b0965c4eb603af5d97733775df315ba2241a1
[llvm-extract] Don't forget to link to Analysis component

```
[ 50% 1/2][ 50% 00:01 + 00:01] Linking CXX executable bin/llvm-extract
FAILED: bin/llvm-extract
: && /usr/bin/clang++-15 -O3 -g -ggdb -march=native -UNDEBUG -gsplit-dwarf -gz -fPIC -fno-semantic-interposition -fvisibility-inlines-hidden -Werror=date-time -Werror=unguarded-availability-new -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wmissing-field-initializers -pedantic -Wno-long-long -Wc++98-compat-extra-semi -Wimplicit-fallthrough -Wcovered-switch-default -Wno-noexcept-type -Wnon-virtual-dtor -Wdelete-non-virtual-dtor -Wsuggest-override -Wstring-conversion -Wmisleading-indentation -Wctad-maybe-unsupported -fdiagnostics-color -ffunction-sections -fdata-sections -O3 -g -ggdb -march=native -UNDEBUG -gsplit-dwarf -gz -Wl,--gdb-index -Wl,--color-diagnostics     -Wl,--gc-sections tools/llvm-extract/CMakeFiles/llvm-extract.dir/llvm-extract.cpp.o -o bin/llvm-extract  -Wl,-rpath,"\$ORIGIN/../lib"  lib/libLLVMPasses.so.16git  lib/libLLVMIRPrinter.so.16git  lib/libLLVMipo.so.16git  lib/libLLVMBitWriter.so.16git  lib/libLLVMIRReader.so.16git  lib/libLLVMCore.so.16git  lib/libLLVMSupport.so.16git  -Wl,-rpath-link,/builddirs/llvm-project/build-Clang15/lib && :
ld: error: undefined symbol: llvm::AnalysisManager<llvm::Loop, llvm::LoopStandardAnalysisResults&>::AnalysisManager()
>>> referenced by llvm-extract.cpp:326 (/repositories/llvm-project/llvm/tools/llvm-extract/llvm-extract.cpp:326)
>>>               tools/llvm-extract/CMakeFiles/llvm-extract.dir/llvm-extract.cpp.o:(main)
>>> referenced by llvm-extract.cpp:373 (/repositories/llvm-project/llvm/tools/llvm-extract/llvm-extract.cpp:373)
>>>               tools/llvm-extract/CMakeFiles/llvm-extract.dir/llvm-extract.cpp.o:(main)
>>> referenced by llvm-extract.cpp:394 (/repositories/llvm-project/llvm/tools/llvm-extract/llvm-extract.cpp:394)
>>>               tools/llvm-extract/CMakeFiles/llvm-extract.dir/llvm-extract.cpp.o:(main)

ld: error: undefined symbol: llvm::AnalysisManager<llvm::LazyCallGraph::SCC, llvm::LazyCallGraph&>::AnalysisManager()
>>> referenced by llvm-extract.cpp:328 (/repositories/llvm-project/llvm/tools/llvm-extract/llvm-extract.cpp:328)
>>>               tools/llvm-extract/CMakeFiles/llvm-extract.dir/llvm-extract.cpp.o:(main)
>>> referenced by llvm-extract.cpp:375 (/repositories/llvm-project/llvm/tools/llvm-extract/llvm-extract.cpp:375)
>>>               tools/llvm-extract/CMakeFiles/llvm-extract.dir/llvm-extract.cpp.o:(main)
>>> referenced by llvm-extract.cpp:396 (/repositories/llvm-project/llvm/tools/llvm-extract/llvm-extract.cpp:396)
>>>               tools/llvm-extract/CMakeFiles/llvm-extract.dir/llvm-extract.cpp.o:(main)
clang: error: linker command failed with exit code 1 (use -v to see invocation)
ninja: build stopped: subcommand failed.
```
llvm/tools/llvm-extract/CMakeLists.txt