facf0c92e0
Red Bear OS is a full fork. All sources must be available from git clone with zero network access. Removed gitignore rules that excluded fetched source trees under recipes/*/source/, local/recipes/kde/*/source/, local/recipes/qt/*/source/, and vendor source trees. Build artifacts (target/, build/, source.tar, *.o, *.so) remain excluded. 127291 files added — kernel, relibc, base, bootloader, pkgar, all KDE/Qt frameworks, mesa, wayland, DRM drivers, and every other recipe source.
62 lines
1.3 KiB
Bash
Executable File
62 lines
1.3 KiB
Bash
Executable File
#! /bin/sh
|
|
. "${srcdir=.}/init.sh"; path_prepend_ . ../src
|
|
|
|
# Test of gettext facilities in the PO/POT format.
|
|
|
|
# Test with POT format.
|
|
|
|
cat <<\EOF > prog-in.pot
|
|
msgid "'Your command, please?', asked the waiter."
|
|
msgstr ""
|
|
|
|
#, c-format
|
|
msgid "a piece of cake"
|
|
msgid_plural "%d pieces of cake"
|
|
msgstr[0] ""
|
|
msgstr[1] ""
|
|
|
|
#, c-format
|
|
msgid "%s is replaced by %s."
|
|
msgstr ""
|
|
EOF
|
|
|
|
: ${XGETTEXT=xgettext}
|
|
${XGETTEXT} -o prog.tmp --omit-header --add-location prog-in.pot || Exit 1
|
|
LC_ALL=C tr -d '\r' < prog.tmp > prog.pot || Exit 1
|
|
|
|
: ${DIFF=diff}
|
|
${DIFF} prog-in.pot prog.pot || Exit 1
|
|
|
|
# Test with PO format.
|
|
|
|
cat <<\EOF > prog-in.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.
|
|
#, c-format
|
|
msgid "a piece of cake"
|
|
msgid_plural "%d pieces of cake"
|
|
msgstr[0] "un morceau de gateau"
|
|
msgstr[1] "%d morceaux de gateau"
|
|
|
|
# Reverse the arguments.
|
|
#, c-format
|
|
msgid "%s is replaced by %s."
|
|
msgstr "%2$s remplace %1$s."
|
|
EOF
|
|
|
|
: ${XGETTEXT=xgettext}
|
|
${XGETTEXT} -o prog.tmp.po --omit-header --add-location prog-in.po || Exit 1
|
|
LC_ALL=C tr -d '\r' < prog.tmp.po > prog.po || Exit 1
|
|
|
|
: ${DIFF=diff}
|
|
${DIFF} prog-in.po prog.po || Exit 1
|
|
|
|
Exit 0
|