blob: fbbd5cced9fbc574a0562f0ce2ce9150c7b3c7eb (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
|
#! /bin/sh
. "${srcdir=.}/init.sh"; path_prepend_ . ../src
# Test of --csharp option.
# Test whether we can compile and execute C# programs.
test "${CSHARP_CHOICE}" != no || {
echo "Skipping test: configured with --disable-csharp"
Exit 77
}
test "${BUILDCSHARP}" = yes || {
echo "Skipping test: C# compiler not found"
Exit 77
}
test "${TESTCSHARP}" = yes || {
echo "Skipping test: C# engine not found"
Exit 77
}
test -d mu-cs-1 || mkdir mu-cs-1
cat <<\EOF > mu-cs-1/fr.po
msgid ""
msgstr ""
"Content-Type: text/plain; charset=ISO-8859-1\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
msgid "'Your command, please?', asked the waiter."
msgstr "«Votre commande, s'il vous plait», dit le garçon."
# Les gateaux allemands sont les meilleurs du monde.
#, csharp-format
msgid "a piece of cake"
msgid_plural "{0} pieces of cake"
msgstr[0] "un morceau de gateau"
msgstr[1] "{0} morceaux de gateau"
# Reverse the arguments.
#, csharp-format
msgid "{0} is replaced by {1}."
msgstr "{1} remplace {0}."
# A proximity measure.
msgid "Close"
msgstr "Proche"
# A menu entry.
msgctxt "File"
msgid "Close"
msgstr "Fermer"
EOF
: ${MSGFMT=msgfmt}
GETTEXTCSHARPLIBDIR=../../../gettext-runtime/intl-csharp \
${MSGFMT} --csharp -d mu-cs-1 -r prog -l fr mu-cs-1/fr.po || Exit 1
: ${MSGUNFMT=msgunfmt}
GETTEXTCSHARPEXEDIR=../../src \
GETTEXTCSHARPLIBDIR=../../../gettext-runtime/intl-csharp \
${MSGUNFMT} --csharp -d mu-cs-1 -r prog -l fr -o mu-cs-1/prog.out || Exit 1
: ${MSGCAT=msgcat}
${MSGCAT} -s -o mu-cs-1/prog.sort mu-cs-1/prog.out || Exit 1
cat <<\EOF > mu-cs-1/prog.ok
msgid ""
msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
msgid "'Your command, please?', asked the waiter."
msgstr "«Votre commande, s'il vous plait», dit le garçon."
msgid "Close"
msgstr "Proche"
msgctxt "File"
msgid "Close"
msgstr "Fermer"
msgid "a piece of cake"
msgid_plural "{0} pieces of cake"
msgstr[0] "un morceau de gateau"
msgstr[1] "{0} morceaux de gateau"
msgid "{0} is replaced by {1}."
msgstr "{1} remplace {0}."
EOF
: ${DIFF=diff}
${DIFF} mu-cs-1/prog.ok mu-cs-1/prog.sort || Exit 1
Exit 0
|