This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug driver/46617] New: String concatenation fools extraction for translation.
- From: "goeran at uddeborg dot se" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Tue, 23 Nov 2010 10:46:44 +0000
- Subject: [Bug driver/46617] New: String concatenation fools extraction for translation.
- Auto-submitted: auto-generated
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46617
Summary: String concatenation fools extraction for translation.
Product: gcc
Version: 4.6.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: driver
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: goeran@uddeborg.se
In gcc-4.6-20101113 in gcc/gcc.c in main() there is this code:
fatal_error ("-fuse-linker-plugin, but " LTOPLUGINSONAME " not found");
When extracting strings for translation, the extractor doesn't see this as one
long string, and does not know what to replace LTOPLUGINSONAME with. The
result is that what winds up in the pot file is
#: gcc.c:6830
#, gcc-internal-format
msgid "-fuse-linker-plugin, but "
Obviously incorrect.
As a simple fix, may I suggest to rewrite it using a percent substitution:
fatal_error ("-fuse-linker-plugin, but %s not found", LTOPLUGINSONAME);