1 |
# Makefile for PO directory in any package using GNU gettext. |
# Makefile for PO directory in any package using GNU gettext. |
2 |
# Copyright (C) 1995-1997, 2000-2003 by Ulrich Drepper <drepper@gnu.ai.mit.edu> |
# Copyright (C) 1995-1997, 2000-2004 by Ulrich Drepper <drepper@gnu.ai.mit.edu> |
3 |
# |
# |
4 |
# This file can be copied and used freely without restrictions. It can |
# This file can be copied and used freely without restrictions. It can |
5 |
# be used in projects which are not available under the GNU General Public |
# be used in projects which are not available under the GNU General Public |
8 |
# Please note that the actual code of GNU gettext is covered by the GNU |
# Please note that the actual code of GNU gettext is covered by the GNU |
9 |
# General Public License and is *not* in the public domain. |
# General Public License and is *not* in the public domain. |
10 |
# |
# |
11 |
# Origin: gettext-0.13 |
# Origin: gettext-0.14 |
12 |
|
|
13 |
PACKAGE = @PACKAGE@ |
PACKAGE = @PACKAGE@ |
14 |
VERSION = @VERSION@ |
VERSION = @VERSION@ |
22 |
|
|
23 |
prefix = @prefix@ |
prefix = @prefix@ |
24 |
exec_prefix = @exec_prefix@ |
exec_prefix = @exec_prefix@ |
25 |
datadir = @datadir@ |
datadir = @gamedatadir@ |
26 |
localedir = $(datadir)/locale |
localedir = $(datadir)/locale |
27 |
gettextsrcdir = $(datadir)/gettext/po |
gettextsrcdir = $(datadir)/gettext/po |
28 |
|
|
57 |
# Makevars gets inserted here. (Don't remove this line!) |
# Makevars gets inserted here. (Don't remove this line!) |
58 |
|
|
59 |
.SUFFIXES: |
.SUFFIXES: |
60 |
.SUFFIXES: .po .gmo .mo .sed .sin .nop .po-update |
.SUFFIXES: .po .gmo .mo .sed .sin .nop .po-create .po-update |
61 |
|
|
62 |
.po.mo: |
.po.mo: |
63 |
@echo "$(MSGFMT) -c -o $@ $<"; \ |
@echo "$(MSGFMT) -c -o $@ $<"; \ |
130 |
# Note that a PO file is not touched if it doesn't need to be changed. |
# Note that a PO file is not touched if it doesn't need to be changed. |
131 |
$(POFILES): $(srcdir)/$(DOMAIN).pot |
$(POFILES): $(srcdir)/$(DOMAIN).pot |
132 |
@lang=`echo $@ | sed -e 's,.*/,,' -e 's/\.po$$//'`; \ |
@lang=`echo $@ | sed -e 's,.*/,,' -e 's/\.po$$//'`; \ |
133 |
test "$(srcdir)" = . && cdcmd="" || cdcmd="cd $(srcdir) && "; \ |
if test -f "$(srcdir)/$${lang}.po"; then \ |
134 |
echo "$${cdcmd}$(MSGMERGE_UPDATE) $${lang}.po $(DOMAIN).pot"; \ |
test "$(srcdir)" = . && cdcmd="" || cdcmd="cd $(srcdir) && "; \ |
135 |
cd $(srcdir) && $(MSGMERGE_UPDATE) $${lang}.po $(DOMAIN).pot |
echo "$${cdcmd}$(MSGMERGE_UPDATE) $${lang}.po $(DOMAIN).pot"; \ |
136 |
|
cd $(srcdir) && $(MSGMERGE_UPDATE) $${lang}.po $(DOMAIN).pot; \ |
137 |
|
else \ |
138 |
|
$(MAKE) $${lang}.po-create; \ |
139 |
|
fi |
140 |
|
|
141 |
|
|
142 |
install: install-exec install-data |
install: install-exec install-data |
316 |
test -z "$(UPDATEPOFILES)" || $(MAKE) $(UPDATEPOFILES) |
test -z "$(UPDATEPOFILES)" || $(MAKE) $(UPDATEPOFILES) |
317 |
$(MAKE) update-gmo |
$(MAKE) update-gmo |
318 |
|
|
319 |
|
# General rule for creating PO files. |
320 |
|
|
321 |
|
.nop.po-create: |
322 |
|
@lang=`echo $@ | sed -e 's/\.po-create$$//'`; \ |
323 |
|
echo "File $$lang.po does not exist. If you are a translator, you can create it through 'msginit'." 1>&2; \ |
324 |
|
exit 1 |
325 |
|
|
326 |
# General rule for updating PO files. |
# General rule for updating PO files. |
327 |
|
|
328 |
.nop.po-update: |
.nop.po-update: |