Fix -fuse-ld option to accept string argument.
authorCary Coutant <ccoutant@gmail.com>
Mon, 15 Jan 2018 18:05:54 +0000 (10:05 -0800)
committerCary Coutant <ccoutant@gmail.com>
Mon, 15 Jan 2018 18:07:11 +0000 (10:07 -0800)
PR 22042 complained that garbage text was being printed in the help
for the -fuse-ld option; this was caused by passing an empty string
to the gettext() function, which sometimes returns garbage when passed
an empty string. The quick fix was to replace "" with NULL as the helparg,
but that changed the parsing of the option, as gold uses the helparg to
determine whether an option takes an argument. This patch adds a
non-empty helparg string to fix both problems.

gold/
PR gold/22694
* options.h (-fuse-ld): Add correct helparg.

gold/ChangeLog
gold/options.h

index a2ee8044c4e41c8adb3d74925f56bfb8e8244a04..6494b20e0e8e495491a6b318fa45fd05db3e200b 100644 (file)
@@ -1,3 +1,8 @@
+2018-01-15  Cary Coutant  <ccoutant@gmail.com>
+
+       PR gold/22694
+       * options.h (-fuse-ld): Add correct helparg.
+
 2018-01-15  Nick Clifton  <nickc@redhat.com>
 
        * po/uk.po: Updated Ukranian translation.
index d5b8fe43ac25d6a2bbde7adf11af65adb7166a79..feb60cc18f855fdd183a110719eefec736c2c089 100644 (file)
@@ -894,7 +894,7 @@ class General_options
 
   DEFINE_string(fuse_ld, options::ONE_DASH, '\0', "",
                N_("Ignored for GCC linker option compatibility"),
-               NULL);
+               N_("[gold,bfd]"));
 
   // g
 
This page took 0.027931 seconds and 4 git commands to generate.