Mercurial > hg > CbC > CbC_gcc
diff gcc/plugin.c @ 145:1830386684a0
gcc-9.2.0
author | anatofuz |
---|---|
date | Thu, 13 Feb 2020 11:34:05 +0900 |
parents | 84e7813d76e9 |
children |
line wrap: on
line diff
--- a/gcc/plugin.c Thu Oct 25 07:37:49 2018 +0900 +++ b/gcc/plugin.c Thu Feb 13 11:34:05 2020 +0900 @@ -1,5 +1,5 @@ /* Support for GCC plugin mechanism. - Copyright (C) 2009-2018 Free Software Foundation, Inc. + Copyright (C) 2009-2020 Free Software Foundation, Inc. This file is part of GCC. @@ -231,7 +231,7 @@ { plugin = (struct plugin_name_args *) *slot; if (strcmp (plugin->full_name, plugin_name)) - error ("plugin %s was specified with different paths:\n%s\n%s", + error ("plugin %qs was specified with different paths: %qs and %qs", plugin->base_name, plugin->full_name, plugin_name); return; } @@ -290,7 +290,8 @@ if (!key_start) { - error ("malformed option -fplugin-arg-%s (missing -<key>[=<value>])", + error ("malformed option %<-fplugin-arg-%s%>: " + "missing %<-<key>[=<value>]%>", arg); return; } @@ -353,7 +354,7 @@ plugin->argv[plugin->argc - 1].value = value; } else - error ("plugin %s should be specified before -fplugin-arg-%s " + error ("plugin %s should be specified before %<-fplugin-arg-%s%> " "in the command line", name, arg); /* We don't need the plugin's name anymore. Just release it. */ @@ -700,7 +701,7 @@ dl_handle = dlopen (plugin->full_name, RTLD_NOW | RTLD_GLOBAL); if (!dl_handle) { - error ("cannot load plugin %s\n%s", plugin->full_name, dlerror ()); + error ("cannot load plugin %s: %s", plugin->full_name, dlerror ()); return false; } @@ -710,17 +711,17 @@ /* Check the plugin license. */ if (dlsym (dl_handle, str_license) == NULL) fatal_error (input_location, - "plugin %s is not licensed under a GPL-compatible license\n" - "%s", plugin->full_name, dlerror ()); + "plugin %s is not licensed under a GPL-compatible license" + " %s", plugin->full_name, dlerror ()); - PTR_UNION_AS_VOID_PTR (plugin_init_union) = - dlsym (dl_handle, str_plugin_init_func_name); + PTR_UNION_AS_VOID_PTR (plugin_init_union) + = dlsym (dl_handle, str_plugin_init_func_name); plugin_init = PTR_UNION_AS_CAST_PTR (plugin_init_union); if ((err = dlerror ()) != NULL) { dlclose(dl_handle); - error ("cannot find %s in plugin %s\n%s", str_plugin_init_func_name, + error ("cannot find %s in plugin %s: %s", str_plugin_init_func_name, plugin->full_name, err); return false; } @@ -729,7 +730,7 @@ if ((*plugin_init) (plugin, &gcc_version)) { dlclose(dl_handle); - error ("fail to initialize plugin %s", plugin->full_name); + error ("failed to initialize plugin %s", plugin->full_name); return false; } /* leak dl_handle on purpose to ensure the plugin is loaded for the @@ -1003,6 +1004,6 @@ { if (!plugindir_string) fatal_error (input_location, - "-iplugindir <dir> option not passed from the gcc driver"); + "%<-iplugindir%> <dir> option not passed from the gcc driver"); return plugindir_string; }