Add the relevant magic bits to allow "-mllvm=-load=plugin.so" etc.
This is now using export_executable_symbols_for_plugins, so symbols are
only exported if plugins are enabled.
Differential Revision: https://reviews.llvm.org/D75879
add_lld_tool(lld
lld.cpp
+
+ ENABLE_PLUGINS
+ SUPPORT_PLUGINS
)
+export_executable_symbols_for_plugins(lld)
target_link_libraries(lld
PRIVATE
#include "llvm/Support/Host.h"
#include "llvm/Support/InitLLVM.h"
#include "llvm/Support/Path.h"
+#include "llvm/Support/PluginLoader.h"
#include <cstdlib>
using namespace lld;