]> granicus.if.org Git - clang/commitdiff
Revert r276856 "Adjust Registry interface to not require plugins to export a registry"
authorJohn Brawn <john.brawn@arm.com>
Wed, 27 Jul 2016 11:41:18 +0000 (11:41 +0000)
committerJohn Brawn <john.brawn@arm.com>
Wed, 27 Jul 2016 11:41:18 +0000 (11:41 +0000)
This is causing a huge pile of buildbot failures.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@276857 91177308-0d34-0410-b5e6-96231b3b80d8

examples/AnnotateFunctions/CMakeLists.txt
examples/PrintFunctionNames/CMakeLists.txt
include/clang/Frontend/FrontendPluginRegistry.h
include/clang/Lex/Preprocessor.h
lib/Frontend/FrontendAction.cpp
lib/Lex/Preprocessor.cpp
lib/Tooling/CompilationDatabase.cpp

index 5684abf2380d14ccea063a5629737560fc36cd36..cf564d527d6a8f692599024eed62a4578c3d83ff 100644 (file)
@@ -1,4 +1,4 @@
-add_llvm_loadable_module(AnnotateFunctions AnnotateFunctions.cpp PLUGIN_TOOL clang)
+add_llvm_loadable_module(AnnotateFunctions AnnotateFunctions.cpp)
 
 if(LLVM_ENABLE_PLUGINS AND (WIN32 OR CYGWIN))
   target_link_libraries(AnnotateFunctions PRIVATE
index f5f818866ca60e9f89489d04b23532c87a076f4e..5a00d5036fb1631be836365652f40851eece869c 100644 (file)
@@ -9,7 +9,7 @@ if( NOT MSVC ) # MSVC mangles symbols differently, and
   endif()
 endif()
 
-add_llvm_loadable_module(PrintFunctionNames PrintFunctionNames.cpp PLUGIN_TOOL clang)
+add_llvm_loadable_module(PrintFunctionNames PrintFunctionNames.cpp)
 
 if(LLVM_ENABLE_PLUGINS AND (WIN32 OR CYGWIN))
   target_link_libraries(PrintFunctionNames PRIVATE
index 9d7ee08d95d4b5dcab31d97e0177d35782337ede..ecab630c1228c9adac60a33319c9615c82e9a142 100644 (file)
@@ -13,6 +13,9 @@
 #include "clang/Frontend/FrontendAction.h"
 #include "llvm/Support/Registry.h"
 
+// Instantiated in FrontendAction.cpp.
+extern template class llvm::Registry<clang::PluginASTAction>;
+
 namespace clang {
 
 /// The frontend plugin registry.
index 4a46bb8d05f54ddf90a6e6cbb61ae18804e422e6..30cc37f6f884fb26567ed267bef7082b4a7e3c08 100644 (file)
@@ -1956,4 +1956,6 @@ typedef llvm::Registry<PragmaHandler> PragmaHandlerRegistry;
 
 }  // end namespace clang
 
+extern template class llvm::Registry<clang::PragmaHandler>;
+
 #endif
index 2945b8925f9b2404349a6c314ba13224a312155d..d2c2a80394db860578abd112506f309da305de83 100644 (file)
@@ -33,7 +33,7 @@
 #include <system_error>
 using namespace clang;
 
-LLVM_INSTANTIATE_REGISTRY(FrontendPluginRegistry)
+template class llvm::Registry<clang::PluginASTAction>;
 
 namespace {
 
index 6812da821297df5c624e6beaaa6431702c037782..3654ba080d47c49c9b3b0038d20d6451af3f8ee7 100644 (file)
@@ -54,7 +54,7 @@
 #include <utility>
 using namespace clang;
 
-LLVM_INSTANTIATE_REGISTRY(PragmaHandlerRegistry)
+template class llvm::Registry<clang::PragmaHandler>;
 
 //===----------------------------------------------------------------------===//
 ExternalPreprocessorSource::~ExternalPreprocessorSource() { }
index 6f95bf01f690bd827da820fe4fbe5f39bae95470..8fc4a1fe5beb0d2d8b022aaf25c179114420954e 100644 (file)
@@ -32,8 +32,6 @@
 using namespace clang;
 using namespace tooling;
 
-LLVM_INSTANTIATE_REGISTRY(CompilationDatabasePluginRegistry)
-
 CompilationDatabase::~CompilationDatabase() {}
 
 std::unique_ptr<CompilationDatabase>