Simplified project configuration for translations (fixes "make distclean")
This commit is contained in:
parent
23d78a40ea
commit
4fcd919063
19
po/Makefile
19
po/Makefile
|
@ -1,4 +1,4 @@
|
||||||
TARGETS = Surfer.pot de.po de.mo es.po es.mo fr.po fr.mo
|
TARGETS = Surfer.pot de.mo es.mo fr.mo
|
||||||
RM = rm -f
|
RM = rm -f
|
||||||
LN = ln -f
|
LN = ln -f
|
||||||
MKDIR = mkdir -p
|
MKDIR = mkdir -p
|
||||||
|
@ -10,26 +10,17 @@ all: $(TARGETS)
|
||||||
Surfer.pot: POTFILES
|
Surfer.pot: POTFILES
|
||||||
./gettext.sh "Surfer.pot"
|
./gettext.sh "Surfer.pot"
|
||||||
|
|
||||||
de.po: Surfer.pot
|
de.mo: Surfer.pot de.po
|
||||||
./gettext.sh "de.po"
|
|
||||||
|
|
||||||
de.mo: de.po
|
|
||||||
./gettext.sh "de.mo"
|
./gettext.sh "de.mo"
|
||||||
|
|
||||||
es.po: Surfer.pot
|
es.mo: Surfer.pot es.po
|
||||||
./gettext.sh "es.po"
|
|
||||||
|
|
||||||
es.mo: es.po
|
|
||||||
./gettext.sh "es.mo"
|
./gettext.sh "es.mo"
|
||||||
|
|
||||||
fr.po: Surfer.pot
|
fr.mo: Surfer.pot fr.po
|
||||||
./gettext.sh "fr.po"
|
|
||||||
|
|
||||||
fr.mo: fr.po
|
|
||||||
./gettext.sh "fr.mo"
|
./gettext.sh "fr.mo"
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
$(RM) $(Surfer.pot_OBJS) $(de.po_OBJS) $(de.mo_OBJS) $(es.po_OBJS) $(es.mo_OBJS) $(fr.po_OBJS) $(fr.mo_OBJS)
|
$(RM) $(Surfer.pot_OBJS) $(de.mo_OBJS) $(es.mo_OBJS) $(fr.mo_OBJS)
|
||||||
|
|
||||||
distclean: clean
|
distclean: clean
|
||||||
$(RM) $(TARGETS)
|
$(RM) $(TARGETS)
|
||||||
|
|
10
po/de.po
10
po/de.po
|
@ -9,7 +9,7 @@ msgstr ""
|
||||||
"Report-Msgid-Bugs-To: \n"
|
"Report-Msgid-Bugs-To: \n"
|
||||||
"POT-Creation-Date: 2010-04-05 03:40+0200\n"
|
"POT-Creation-Date: 2010-04-05 03:40+0200\n"
|
||||||
"PO-Revision-Date: 2010-04-01 19:40+0200\n"
|
"PO-Revision-Date: 2010-04-01 19:40+0200\n"
|
||||||
"Last-Translator: Pierre Pronchery <EMAIL@ADDRESS>\n"
|
"Last-Translator: Pierre Pronchery <khorben@defora.org>\n"
|
||||||
"Language-Team: German\n"
|
"Language-Team: German\n"
|
||||||
"MIME-Version: 1.0\n"
|
"MIME-Version: 1.0\n"
|
||||||
"Content-Type: text/plain; charset=ISO-8859-15\n"
|
"Content-Type: text/plain; charset=ISO-8859-15\n"
|
||||||
|
@ -204,19 +204,19 @@ msgstr "Fehler"
|
||||||
msgid "Unknown error"
|
msgid "Unknown error"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: ../src/surfer.c:529
|
#: ../src/surfer.c:537
|
||||||
msgid "Find text"
|
msgid "Find text"
|
||||||
msgstr "Suchen"
|
msgstr "Suchen"
|
||||||
|
|
||||||
#: ../src/surfer.c:536
|
#: ../src/surfer.c:544
|
||||||
msgid "Text:"
|
msgid "Text:"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: ../src/surfer.c:545
|
#: ../src/surfer.c:551
|
||||||
msgid "Case-sensitive"
|
msgid "Case-sensitive"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: ../src/surfer.c:548
|
#: ../src/surfer.c:553
|
||||||
msgid "Wrap"
|
msgid "Wrap"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
|
|
8
po/es.po
8
po/es.po
|
@ -204,19 +204,19 @@ msgstr ""
|
||||||
msgid "Unknown error"
|
msgid "Unknown error"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: ../src/surfer.c:529
|
#: ../src/surfer.c:537
|
||||||
msgid "Find text"
|
msgid "Find text"
|
||||||
msgstr "Buscar"
|
msgstr "Buscar"
|
||||||
|
|
||||||
#: ../src/surfer.c:536
|
#: ../src/surfer.c:544
|
||||||
msgid "Text:"
|
msgid "Text:"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: ../src/surfer.c:545
|
#: ../src/surfer.c:551
|
||||||
msgid "Case-sensitive"
|
msgid "Case-sensitive"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: ../src/surfer.c:548
|
#: ../src/surfer.c:553
|
||||||
msgid "Wrap"
|
msgid "Wrap"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
|
|
8
po/fr.po
8
po/fr.po
|
@ -204,19 +204,19 @@ msgstr "Erreur"
|
||||||
msgid "Unknown error"
|
msgid "Unknown error"
|
||||||
msgstr "Erreur inconnue"
|
msgstr "Erreur inconnue"
|
||||||
|
|
||||||
#: ../src/surfer.c:529
|
#: ../src/surfer.c:537
|
||||||
msgid "Find text"
|
msgid "Find text"
|
||||||
msgstr "Chercher du texte"
|
msgstr "Chercher du texte"
|
||||||
|
|
||||||
#: ../src/surfer.c:536
|
#: ../src/surfer.c:544
|
||||||
msgid "Text:"
|
msgid "Text:"
|
||||||
msgstr "Texte: "
|
msgstr "Texte: "
|
||||||
|
|
||||||
#: ../src/surfer.c:545
|
#: ../src/surfer.c:551
|
||||||
msgid "Case-sensitive"
|
msgid "Case-sensitive"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: ../src/surfer.c:548
|
#: ../src/surfer.c:553
|
||||||
msgid "Wrap"
|
msgid "Wrap"
|
||||||
msgstr "Chercher en boucle"
|
msgstr "Chercher en boucle"
|
||||||
|
|
||||||
|
|
|
@ -35,25 +35,17 @@ _debug()
|
||||||
|
|
||||||
#gettext_mo
|
#gettext_mo
|
||||||
_gettext_mo()
|
_gettext_mo()
|
||||||
{
|
|
||||||
lang="$2"
|
|
||||||
|
|
||||||
$DEBUG $MSGFMT -c -v -o "$lang.mo" "$lang.po" || return 1
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
#gettext_po
|
|
||||||
_gettext_po()
|
|
||||||
{
|
{
|
||||||
package="$1"
|
package="$1"
|
||||||
lang="$2"
|
lang="$2"
|
||||||
|
|
||||||
if [ -f "$lang.po" ]; then
|
if [ -f "$lang.po" ]; then
|
||||||
$DEBUG $MSGMERGE -U "$lang.po" "$package.pot" || return 1
|
$DEBUG $MSGMERGE -U "$lang.po" "$package.pot" || return 1
|
||||||
return 0
|
else
|
||||||
fi
|
|
||||||
$DEBUG $MSGINIT -l "$lang" -o "$lang.po" -i "$package.pot" \
|
$DEBUG $MSGINIT -l "$lang" -o "$lang.po" -i "$package.pot" \
|
||||||
|| return 1
|
|| return 1
|
||||||
|
fi
|
||||||
|
$DEBUG $MSGFMT -c -v -o "$lang.mo" "$lang.po" || return 1
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -85,9 +77,6 @@ case "$1" in
|
||||||
*.mo)
|
*.mo)
|
||||||
_gettext_mo "$PACKAGE" "${1%%.mo}" || exit 2
|
_gettext_mo "$PACKAGE" "${1%%.mo}" || exit 2
|
||||||
;;
|
;;
|
||||||
*.po)
|
|
||||||
_gettext_po "$PACKAGE" "${1%%.po}" || exit 2
|
|
||||||
;;
|
|
||||||
*.pot)
|
*.pot)
|
||||||
_gettext_pot "${1%%.pot}" || exit 2
|
_gettext_pot "${1%%.pot}" || exit 2
|
||||||
;;
|
;;
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
targets=Surfer.pot,de.po,de.mo,es.po,es.mo,fr.po,fr.mo
|
targets=Surfer.pot,de.mo,es.mo,fr.mo
|
||||||
dist=Makefile,gettext.sh,POTFILES,de.po,es.po,fr.po
|
dist=Makefile,gettext.sh,POTFILES,de.po,es.po,fr.po
|
||||||
|
|
||||||
[Surfer.pot]
|
[Surfer.pot]
|
||||||
|
@ -6,35 +6,20 @@ type=script
|
||||||
script=./gettext.sh
|
script=./gettext.sh
|
||||||
depends=POTFILES
|
depends=POTFILES
|
||||||
|
|
||||||
[de.po]
|
|
||||||
type=script
|
|
||||||
script=./gettext.sh
|
|
||||||
depends=Surfer.pot
|
|
||||||
|
|
||||||
[de.mo]
|
[de.mo]
|
||||||
type=script
|
type=script
|
||||||
script=./gettext.sh
|
script=./gettext.sh
|
||||||
install=
|
install=
|
||||||
depends=de.po
|
depends=Surfer.pot,de.po
|
||||||
|
|
||||||
[es.po]
|
|
||||||
type=script
|
|
||||||
script=./gettext.sh
|
|
||||||
depends=Surfer.pot
|
|
||||||
|
|
||||||
[es.mo]
|
[es.mo]
|
||||||
type=script
|
type=script
|
||||||
script=./gettext.sh
|
script=./gettext.sh
|
||||||
install=
|
install=
|
||||||
depends=es.po
|
depends=Surfer.pot,es.po
|
||||||
|
|
||||||
[fr.po]
|
|
||||||
type=script
|
|
||||||
script=./gettext.sh
|
|
||||||
depends=Surfer.pot
|
|
||||||
|
|
||||||
[fr.mo]
|
[fr.mo]
|
||||||
type=script
|
type=script
|
||||||
script=./gettext.sh
|
script=./gettext.sh
|
||||||
install=
|
install=
|
||||||
depends=fr.po
|
depends=Surfer.pot,fr.po
|
||||||
|
|
Loading…
Reference in New Issue
Block a user