From: Bruno Haible Date: Mon, 8 Jan 2007 18:42:31 +0000 (+0000) Subject: Handling of obsolete messages in POT file. X-Git-Tag: v0.17~518 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b78e6b23f9b211ef2ac551699fd300d2b6265fe1;p=thirdparty%2Fgettext.git Handling of obsolete messages in POT file. --- diff --git a/gettext-tools/src/ChangeLog b/gettext-tools/src/ChangeLog index 75ab8448e..93655db1b 100644 --- a/gettext-tools/src/ChangeLog +++ b/gettext-tools/src/ChangeLog @@ -1,3 +1,9 @@ +2007-01-07 Bruno Haible + + * msgmerge.c (message_merge): Copy the obsolete bit from the ref + message. + Reported by Leonardo Fontenelle . + 2006-12-24 Bruno Haible * Makefile.am (AM_CXXFLAGS): New variable. diff --git a/gettext-tools/src/msgmerge.c b/gettext-tools/src/msgmerge.c index ad12d3774..03a672731 100644 --- a/gettext-tools/src/msgmerge.c +++ b/gettext-tools/src/msgmerge.c @@ -1,5 +1,5 @@ /* GNU gettext - internationalization aids - Copyright (C) 1995-1998, 2000-2006 Free Software Foundation, Inc. + Copyright (C) 1995-1998, 2000-2007 Free Software Foundation, Inc. This file was written by Peter Miller This program is free software; you can redistribute it and/or modify @@ -1073,6 +1073,12 @@ message_merge (message_ty *def, message_ty *ref, bool force_fuzzy) result->prev_msgid_plural = prev_msgid_plural; } + /* If the reference message was obsolete, make the resulting message + obsolete. This case doesn't occur for POT files, but users sometimes + use PO files that are themselves the result of msgmerge instead of POT + files. */ + result->obsolete = ref->obsolete; + /* Take the file position comments from the reference file, as they are generated by xgettext. Any in the definition file are old ones collected by previous runs of xgettext and msgmerge. */ diff --git a/gettext-tools/tests/ChangeLog b/gettext-tools/tests/ChangeLog index f8ba4ee1c..85e5e7a1b 100644 --- a/gettext-tools/tests/ChangeLog +++ b/gettext-tools/tests/ChangeLog @@ -1,3 +1,9 @@ +2007-01-07 Bruno Haible + + * msgmerge-20: New file. + * Makefile.am (TESTS): Add it. + Reported by Leonardo Fontenelle . + 2006-12-16 Bruno Haible Make it work with autoconf > 2.61. diff --git a/gettext-tools/tests/Makefile.am b/gettext-tools/tests/Makefile.am index 595d9bc0b..ae9e9541e 100644 --- a/gettext-tools/tests/Makefile.am +++ b/gettext-tools/tests/Makefile.am @@ -1,5 +1,5 @@ ## Makefile for the gettext-tools/tests subdirectory of GNU gettext -## Copyright (C) 1995-1997, 2001-2006 Free Software Foundation, Inc. +## Copyright (C) 1995-1997, 2001-2007 Free Software Foundation, Inc. ## ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -54,7 +54,7 @@ TESTS = gettext-1 gettext-2 gettext-3 gettext-4 gettext-5 gettext-6 gettext-7 \ msgmerge-1 msgmerge-2 msgmerge-3 msgmerge-4 msgmerge-5 msgmerge-6 \ msgmerge-7 msgmerge-8 msgmerge-9 msgmerge-10 msgmerge-11 msgmerge-12 \ msgmerge-13 msgmerge-14 msgmerge-15 msgmerge-16 msgmerge-17 \ - msgmerge-18 msgmerge-19 \ + msgmerge-18 msgmerge-19 msgmerge-20 \ msgmerge-compendium-1 msgmerge-compendium-2 msgmerge-compendium-3 \ msgmerge-compendium-4 msgmerge-compendium-5 msgmerge-compendium-6 \ msgmerge-properties-1 msgmerge-properties-2 \