aboutsummaryrefslogtreecommitdiff
path: root/ld/lexsup.c
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2020-06-21 14:23:46 +0930
committerAlan Modra <amodra@gmail.com>2020-06-21 22:16:10 +0930
commit0381901e629115f5f0d92a27fe74b1814f6f389a (patch)
tree70d1c2ebef5f3039131b03ae96d7af9841a77f03 /ld/lexsup.c
parent48e9cc84058771da089a2e8e652f70ac20a8fac0 (diff)
downloadgdb-0381901e629115f5f0d92a27fe74b1814f6f389a.zip
gdb-0381901e629115f5f0d92a27fe74b1814f6f389a.tar.gz
gdb-0381901e629115f5f0d92a27fe74b1814f6f389a.tar.bz2
Do without ld ENABLE_PLUGINS
Instead, use BFD_SUPPORTS_PLUGINS. * ldfile.c: Replace uses of ENABLE_PLUGINS with BFD_SUPPORTS_PLUGINS. * ldlang.c: Likewise. * ldlang.h: Likewise. * ldlex.h: Likewise. * ldmain.c: Likewise. * lexsup.c: Likewise. * plugin.c: Wrap body of file in #if BFD_SUPPORTS_PLUGINS. * testplug.c: Likewise. * testplug2.c: Likewise. * testplug3.c: Likewise. * testplug4.c: Likewise. * configure.ac (ENABLE_PLUGINS): Don't define AM_CONTITIONAL. * Makefile.am: Remove ENABLE_PLUGINS conditionals. (PLUGIN_CFLAGS): Don't define. (PLUGIN_C, PLUGIN_H, PLUGIN_OBJECT): Likewise. Substitute all uses with plugin file name. * configure: Regenerate. * Makefile.in: Regenerate.
Diffstat (limited to 'ld/lexsup.c')
-rw-r--r--ld/lexsup.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/ld/lexsup.c b/ld/lexsup.c
index d84b334..65a9453 100644
--- a/ld/lexsup.c
+++ b/ld/lexsup.c
@@ -39,9 +39,9 @@
#include "ldver.h"
#include "ldemul.h"
#include "demangle.h"
-#ifdef ENABLE_PLUGINS
+#if BFD_SUPPORTS_PLUGINS
#include "plugin.h"
-#endif /* ENABLE_PLUGINS */
+#endif /* BFD_SUPPORTS_PLUGINS */
#ifndef PATH_SEPARATOR
#if defined (__MSDOS__) || (defined (_WIN32) && ! defined (__CYGWIN32__))
@@ -174,7 +174,7 @@ static const struct ld_option ld_options[] =
'O', NULL, N_("Optimize output file"), ONE_DASH },
{ {"out-implib", required_argument, NULL, OPTION_OUT_IMPLIB},
'\0', N_("FILE"), N_("Generate import library"), TWO_DASHES },
-#ifdef ENABLE_PLUGINS
+#if BFD_SUPPORTS_PLUGINS
{ {"plugin", required_argument, NULL, OPTION_PLUGIN},
'\0', N_("PLUGIN"), N_("Load named plugin"), ONE_DASH },
{ {"plugin-opt", required_argument, NULL, OPTION_PLUGIN_OPT},
@@ -190,7 +190,7 @@ static const struct ld_option ld_options[] =
'\0', N_("PLUGIN"), N_("Load named plugin (ignored)"), ONE_DASH },
{ {"plugin-opt", required_argument, NULL, OPTION_IGNORE},
'\0', N_("ARG"), N_("Send arg to last-loaded plugin (ignored)"), ONE_DASH },
-#endif /* ENABLE_PLUGINS */
+#endif /* BFD_SUPPORTS_PLUGINS */
{ {"fuse-ld=", required_argument, NULL, OPTION_IGNORE},
'\0', NULL, N_("Ignored for GCC linker option compatibility"),
ONE_DASH },
@@ -1066,7 +1066,7 @@ parse_args (unsigned argc, char **argv)
case OPTION_PRINT_OUTPUT_FORMAT:
command_line.print_output_format = TRUE;
break;
-#ifdef ENABLE_PLUGINS
+#if BFD_SUPPORTS_PLUGINS
case OPTION_PLUGIN:
plugin_opt_plugin (optarg);
break;
@@ -1074,7 +1074,7 @@ parse_args (unsigned argc, char **argv)
if (plugin_opt_plugin_arg (optarg))
einfo (_("%F%P: bad -plugin-opt option\n"));
break;
-#endif /* ENABLE_PLUGINS */
+#endif /* BFD_SUPPORTS_PLUGINS */
case 'q':
link_info.emitrelocations = TRUE;
break;
@@ -1368,9 +1368,9 @@ parse_args (unsigned argc, char **argv)
int level ATTRIBUTE_UNUSED = strtoul (optarg, &end, 0);
if (*end)
einfo (_("%F%P: invalid number `%s'\n"), optarg);
-#ifdef ENABLE_PLUGINS
+#if BFD_SUPPORTS_PLUGINS
report_plugin_symbols = level > 1;
-#endif /* ENABLE_PLUGINS */
+#endif /* BFD_SUPPORTS_PLUGINS */
}
break;
case 'v':