xref: /netbsd-src/external/gpl2/gettext/dist/gettext-tools/tests/msgmerge-16 (revision 946379e7b37692fc43f68eb0d1c10daa0a7f3b6c)
1*946379e7Schristos#! /bin/sh
2*946379e7Schristos
3*946379e7Schristos# Test non-ASCII msgids when the PO file and the POT file are in different
4*946379e7Schristos# encodings.
5*946379e7Schristos
6*946379e7Schristostmpfiles=""
7*946379e7Schristostrap 'rm -fr $tmpfiles' 1 2 3 15
8*946379e7Schristos
9*946379e7Schristostmpfiles="$tmpfiles mm-test16.po"
10*946379e7Schristoscat <<\EOF > mm-test16.po
11*946379e7Schristosmsgid ""
12*946379e7Schristosmsgstr ""
13*946379e7Schristos"Project-Id-Version: hello-cplusplus-qt 0\n"
14*946379e7Schristos"Report-Msgid-Bugs-To: bug-gnu-gettext@gnu.org\n"
15*946379e7Schristos"POT-Creation-Date: 2003-10-20 10:14+0200\n"
16*946379e7Schristos"PO-Revision-Date: 2003-10-20 10:13+0200\n"
17*946379e7Schristos"Last-Translator: Bruno Haible <bruno@clisp.org>\n"
18*946379e7Schristos"Language-Team: Polish <pl@li.org>\n"
19*946379e7Schristos"MIME-Version: 1.0\n"
20*946379e7Schristos"Content-Type: text/plain; charset=ISO-8859-2\n"
21*946379e7Schristos"Content-Transfer-Encoding: 8bit\n"
22*946379e7Schristos"Plural-Forms: nplurals=3; plural=(n==1 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 "
23*946379e7Schristos"|| n%100>=20) ? 1 : 2);\n"
24*946379e7Schristos
25*946379e7Schristos#: hello.cc:45
26*946379e7Schristosmsgid "Written by Fran�ois Pinard."
27*946379e7Schristosmsgstr "Program napisa� Fran�ois Pinard."
28*946379e7Schristos
29*946379e7Schristos#: hello.cc:52
30*946379e7Schristosmsgid "error %1."
31*946379e7Schristosmsgstr "b��d %1."
32*946379e7SchristosEOF
33*946379e7Schristos
34*946379e7Schristostmpfiles="$tmpfiles mm-test16.pot"
35*946379e7Schristoscat <<EOF > mm-test16.pot
36*946379e7Schristos# SOME DESCRIPTIVE TITLE.
37*946379e7Schristos# Copyright (C) YEAR Yoyodyne, Inc.
38*946379e7Schristos# This file is distributed under the same license as the PACKAGE package.
39*946379e7Schristos# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
40*946379e7Schristos#
41*946379e7Schristos#, fuzzy
42*946379e7Schristosmsgid ""
43*946379e7Schristosmsgstr ""
44*946379e7Schristos"Project-Id-Version: PACKAGE VERSION\n"
45*946379e7Schristos"Report-Msgid-Bugs-To: bug-gnu-gettext@gnu.org\n"
46*946379e7Schristos"POT-Creation-Date: 2003-10-20 10:14+0200\n"
47*946379e7Schristos"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
48*946379e7Schristos"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
49*946379e7Schristos"Language-Team: LANGUAGE <LL@li.org>\n"
50*946379e7Schristos"MIME-Version: 1.0\n"
51*946379e7Schristos"Content-Type: text/plain; charset=UTF-8\n"
52*946379e7Schristos"Content-Transfer-Encoding: 8bit\n"
53*946379e7Schristos
54*946379e7Schristos#: hello.cc:45
55*946379e7Schristosmsgid "Written by François Pinard."
56*946379e7Schristosmsgstr ""
57*946379e7Schristos
58*946379e7Schristos#: hello.cc:52
59*946379e7Schristosmsgid "error %1."
60*946379e7Schristosmsgstr ""
61*946379e7SchristosEOF
62*946379e7Schristos
63*946379e7Schristostmpfiles="$tmpfiles mm-test16.new.po"
64*946379e7Schristos: ${MSGMERGE=msgmerge}
65*946379e7Schristos${MSGMERGE} -q -o mm-test16.new.po mm-test16.po mm-test16.pot
66*946379e7Schristostest $? = 0 || { rm -fr $tmpfiles; exit 1; }
67*946379e7Schristos
68*946379e7Schristostmpfiles="$tmpfiles mm-test16.ok"
69*946379e7Schristoscat <<\EOF > mm-test16.ok
70*946379e7Schristosmsgid ""
71*946379e7Schristosmsgstr ""
72*946379e7Schristos"Project-Id-Version: hello-cplusplus-qt 0\n"
73*946379e7Schristos"Report-Msgid-Bugs-To: bug-gnu-gettext@gnu.org\n"
74*946379e7Schristos"POT-Creation-Date: 2003-10-20 10:14+0200\n"
75*946379e7Schristos"PO-Revision-Date: 2003-10-20 10:13+0200\n"
76*946379e7Schristos"Last-Translator: Bruno Haible <bruno@clisp.org>\n"
77*946379e7Schristos"Language-Team: Polish <pl@li.org>\n"
78*946379e7Schristos"MIME-Version: 1.0\n"
79*946379e7Schristos"Content-Type: text/plain; charset=UTF-8\n"
80*946379e7Schristos"Content-Transfer-Encoding: 8bit\n"
81*946379e7Schristos"Plural-Forms: nplurals=3; plural=(n==1 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 "
82*946379e7Schristos"|| n%100>=20) ? 1 : 2);\n"
83*946379e7Schristos
84*946379e7Schristos#: hello.cc:45
85*946379e7Schristosmsgid "Written by François Pinard."
86*946379e7Schristosmsgstr "Program napisał François Pinard."
87*946379e7Schristos
88*946379e7Schristos#: hello.cc:52
89*946379e7Schristosmsgid "error %1."
90*946379e7Schristosmsgstr "błąd %1."
91*946379e7SchristosEOF
92*946379e7Schristos
93*946379e7Schristos: ${DIFF=diff}
94*946379e7Schristos${DIFF} mm-test16.ok mm-test16.new.po
95*946379e7Schristosresult=$?
96*946379e7Schristos
97*946379e7Schristosrm -fr $tmpfiles
98*946379e7Schristos
99*946379e7Schristosexit $result
100