[PATCH] D62309: Fix linking of the refactor tweaks directory

Rudolf Kastl via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu May 23 06:19:48 PDT 2019


che666 created this revision.
che666 added a reviewer: clang-tools-extra.
Herald added subscribers: cfe-commits, kadircet, arphaman, jkorous, ilya-biryukov, mgorny.
Herald added a project: clang.

Currently it seems that the linked libs in CMakelists for the refactor tweaks directory is incomplete leading to:

FAILED: lib64/libclangDaemonTweaks.so.9svn 
: && /usr/bin/c++ -fPIC -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fPIC -fvisibility-inlines-hidden -Werror=date-time -std=c++11 -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -Wimplicit-fallthrough -Wno-class-memaccess -Wno-noexcept-type -Wdelete-non-virtual-dtor -Wno-comment -fdiagnostics-color -ffunction-sections -fdata-sections -fno-common -Woverloaded-virtual -fno-strict-aliasing -pedantic -Wno-long-long -O2 -g -DNDEBUG  -Wl,-z,relro -Wl,--as-needed  -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -Wl,-z,defs -Wl,-z,nodelete   -Wl,-rpath-link,/builddir/build/BUILD/clang-r361395/_build/./lib64  -Wl,-O3 -Wl,--gc-sections -shared -Wl,-soname,libclangDaemonTweaks.so.9svn -o lib64/libclangDaemonTweaks.so.9svn tools/extra/clangd/refactor/tweaks/CMakeFiles/obj.clangDaemonTweaks.dir/RawStringLiteral.cpp.o tools/extra/clangd/refactor/tweaks/CMakeFiles/obj.clangDaemonTweaks.dir/SwapIfBranches.cpp.o  lib64/libclangAST.so.9svn lib64/libclangDaemon.so.9svn lib64/libclangToolingCore.so.9svn /usr/lib64/libLLVM-9svn.so && :
/usr/bin/ld: tools/extra/clangd/refactor/tweaks/CMakeFiles/obj.clangDaemonTweaks.dir/RawStringLiteral.cpp.o: in function `clang::clangd::(anonymous namespace)::RawStringLiteral::prepare(clang::clangd::Tweak::Selection const&)':
/builddir/build/BUILD/clang-r361395/_build/../tools/extra/clangd/refactor/tweaks/RawStringLiteral.cpp:60: undefined reference to `clang::SourceManager::isBeforeInTranslationUnit(clang::SourceLocation, clang::SourceLocation) const'
/usr/bin/ld: /builddir/build/BUILD/clang-r361395/_build/../tools/extra/clangd/refactor/tweaks/RawStringLiteral.cpp:64: undefined reference to `clang::SourceManager::getCharacterData(clang::SourceLocation, bool*) const'
collect2: error: ld returned 1 exit status

The above patch fixes the problem.


Repository:
  rCTE Clang Tools Extra

https://reviews.llvm.org/D62309

Files:
  clang-r361395/tools/extra/clangd/refactor/tweaks/CMakeLists.txt


Index: clang-r361395/tools/extra/clangd/refactor/tweaks/CMakeLists.txt
===================================================================
--- clang-r361395/tools/extra/clangd/refactor/tweaks/CMakeLists.txt
+++ clang-r361395/tools/extra/clangd/refactor/tweaks/CMakeLists.txt
@@ -19,4 +19,5 @@
   clangAST
   clangDaemon
   clangToolingCore
+  clangBasic
   )


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D62309.200952.patch
Type: text/x-patch
Size: 359 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20190523/9b6977d2/attachment-0001.bin>


More information about the cfe-commits mailing list