3 # Test of --java option.
5 # Note: This test fails when using gcj from GCC 3.1 and GCC 3.2, due to a bug
6 # (libgcj/6576). It is fixed in GCC 3.3.
9 trap 'rm -fr $tmpfiles' 1 2 3 15
11 # Test whether we can compile and execute Java programs.
12 test "${TESTJAVA}" = yes ||
exit 77
14 tmpfiles
="$tmpfiles fr.po"
18 "Content-Type: text/plain; charset=ISO-8859-1\n"
19 "Plural-Forms: nplurals=2; plural=(n > 1);\n"
21 msgid
"'Your command, please?', asked the waiter."
22 msgstr
"«Votre commande, s'il vous plait», dit le garçon."
24 # Les gateaux allemands sont les meilleurs du monde.
26 msgid
"a piece of cake"
27 msgid_plural
"{0,number} pieces of cake"
28 msgstr
[0] "un morceau de gateau"
29 msgstr
[1] "{0,number} morceaux de gateau"
31 # Reverse the arguments.
33 msgid
"{0} is replaced by {1}."
34 msgstr
"{1} remplace {0}."
37 tmpfiles
="$tmpfiles prog_fr.class"
39 ${MSGFMT} -j -d .
-r prog
-l fr fr.po ||
exit 1
41 tmpfiles
="$tmpfiles prog.out"
42 : ${MSGUNFMT=msgunfmt}
43 CLASSPATH
=.
${CLASSPATH:+:$CLASSPATH} \
44 GETTEXTJEXEDIR
=..
/src GETTEXTJAR
=..
/src
/gettext.jar \
45 ${MSGUNFMT} --java -d .
-r prog
-l fr
-o prog.out ||
exit 1
47 tmpfiles
="$tmpfiles prog.sort"
49 ${MSGCAT} -s prog.out
-o prog.
sort ||
exit 1
51 tmpfiles
="$tmpfiles prog.ok"
55 "Content-Type: text/plain; charset=UTF-8\n"
56 "Plural-Forms: nplurals=2; plural=(n > 1);\n"
58 msgid
"'Your command, please?', asked the waiter."
59 msgstr
"«Votre commande, s'il vous plait», dit le garçon."
61 msgid
"a piece of cake"
62 msgid_plural
"{0,number} pieces of cake"
63 msgstr
[0] "un morceau de gateau"
64 msgstr
[1] "{0,number} morceaux de gateau"
66 msgid
"{0} is replaced by {1}."
67 msgstr
"{1} remplace {0}."
70 ${DIFF} prog.ok prog.
sort ||
exit 1