annotate po/Makefile.in.in @ 4813:9bc0c8a3a0f0

moved private libraries to plugindir to avoid conflict with audacious.
author Yoshiki Yazawa <yaz@honeyplanet.jp>
date Wed, 26 Nov 2008 03:50:00 +0900
parents c10e53092037
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
1 # Makefile for PO directory in any package using GNU gettext.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
2 # Copyright (C) 1995-1997, 2000-2003 by Ulrich Drepper <drepper@gnu.ai.mit.edu>
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
3 #
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
4 # This file can be copied and used freely without restrictions. It can
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
5 # be used in projects which are not available under the GNU General Public
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
6 # License but which still want to provide support for the GNU gettext
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
7 # functionality.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
8 # Please note that the actual code of GNU gettext is covered by the GNU
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
9 # General Public License and is *not* in the public domain.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
10
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
11 PACKAGE = @PACKAGE@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
12 VERSION = @VERSION@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
13
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
14 SHELL = /bin/sh
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
15 @SET_MAKE@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
16
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
17 srcdir = @srcdir@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
18 top_srcdir = @top_srcdir@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
19 VPATH = @srcdir@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
20
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
21 prefix = @prefix@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
22 exec_prefix = @exec_prefix@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
23 datadir = @datadir@
4810
c10e53092037 Add datarootdir as a variable. Not having it causes loud whining from autoconf.
Tony Vroon <chainsaw@gentoo.org>
parents: 0
diff changeset
24 datarootdir = @datarootdir@
0
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
25 localedir = $(datadir)/locale
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
26 gettextsrcdir = $(datadir)/gettext/po
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
27
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
28 INSTALL = @INSTALL@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
29 INSTALL_DATA = @INSTALL_DATA@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
30 MKINSTALLDIRS = @MKINSTALLDIRS@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
31 mkinstalldirs = $(SHELL) $(MKINSTALLDIRS)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
32
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
33 GMSGFMT = @GMSGFMT@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
34 MSGFMT = @MSGFMT@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
35 XGETTEXT = @XGETTEXT@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
36 MSGMERGE = msgmerge
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
37 MSGMERGE_UPDATE = @MSGMERGE@ --update
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
38 MSGINIT = msginit
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
39 MSGCONV = msgconv
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
40 MSGFILTER = msgfilter
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
41
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
42 POFILES = @POFILES@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
43 GMOFILES = @GMOFILES@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
44 UPDATEPOFILES = @UPDATEPOFILES@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
45 DUMMYPOFILES = @DUMMYPOFILES@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
46 DISTFILES.common = Makefile.in.in remove-potcdate.sin \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
47 $(DISTFILES.common.extra1) $(DISTFILES.common.extra2) $(DISTFILES.common.extra3)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
48 DISTFILES = $(DISTFILES.common) Makevars POTFILES.in $(DOMAIN).pot stamp-po \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
49 $(POFILES) $(GMOFILES) \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
50 $(DISTFILES.extra1) $(DISTFILES.extra2) $(DISTFILES.extra3)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
51
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
52 POTFILES = \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
53
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
54 CATALOGS = @CATALOGS@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
55
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
56 # Makevars gets inserted here. (Don't remove this line!)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
57
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
58 .SUFFIXES:
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
59 .SUFFIXES: .po .gmo .mo .sed .sin .nop .po-update
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
60
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
61 .po.mo:
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
62 @echo "$(MSGFMT) -c -o $@ $<"; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
63 $(MSGFMT) -c -o t-$@ $< && mv t-$@ $@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
64
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
65 .po.gmo:
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
66 @lang=`echo $* | sed -e 's,.*/,,'`; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
67 test "$(srcdir)" = . && cdcmd="" || cdcmd="cd $(srcdir) && "; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
68 echo "$${cdcmd}rm -f $${lang}.gmo && $(GMSGFMT) -c --statistics -o $${lang}.gmo $${lang}.po"; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
69 cd $(srcdir) && rm -f $${lang}.gmo && $(GMSGFMT) -c --statistics -o t-$${lang}.gmo $${lang}.po && mv t-$${lang}.gmo $${lang}.gmo
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
70
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
71 .sin.sed:
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
72 sed -e '/^#/d' $< > t-$@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
73 mv t-$@ $@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
74
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
75
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
76 all: all-@USE_NLS@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
77
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
78 all-yes: stamp-po
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
79 all-no:
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
80
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
81 # stamp-po is a timestamp denoting the last time at which the CATALOGS have
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
82 # been loosely updated. Its purpose is that when a developer or translator
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
83 # checks out the package via CVS, and the $(DOMAIN).pot file is not in CVS,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
84 # "make" will update the $(DOMAIN).pot and the $(CATALOGS), but subsequent
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
85 # invocations of "make" will do nothing. This timestamp would not be necessary
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
86 # if updating the $(CATALOGS) would always touch them; however, the rule for
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
87 # $(POFILES) has been designed to not touch files that don't need to be
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
88 # changed.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
89 stamp-po: $(srcdir)/$(DOMAIN).pot
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
90 test -z "$(CATALOGS)" || $(MAKE) $(CATALOGS)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
91 @echo "touch stamp-po"
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
92 @echo timestamp > stamp-poT
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
93 @mv stamp-poT stamp-po
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
94
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
95 # Note: Target 'all' must not depend on target '$(DOMAIN).pot-update',
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
96 # otherwise packages like GCC can not be built if only parts of the source
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
97 # have been downloaded.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
98
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
99 # This target rebuilds $(DOMAIN).pot; it is an expensive operation.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
100 # Note that $(DOMAIN).pot is not touched if it doesn't need to be changed.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
101 $(DOMAIN).pot-update: $(POTFILES) $(srcdir)/POTFILES.in remove-potcdate.sed
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
102 $(XGETTEXT) --default-domain=$(DOMAIN) --directory=$(top_srcdir) \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
103 --add-comments=TRANSLATORS: $(XGETTEXT_OPTIONS) \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
104 --files-from=$(srcdir)/POTFILES.in \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
105 --copyright-holder='$(COPYRIGHT_HOLDER)' \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
106 --msgid-bugs-address='$(MSGID_BUGS_ADDRESS)'
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
107 test ! -f $(DOMAIN).po || { \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
108 if test -f $(srcdir)/$(DOMAIN).pot; then \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
109 sed -f remove-potcdate.sed < $(srcdir)/$(DOMAIN).pot > $(DOMAIN).1po && \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
110 sed -f remove-potcdate.sed < $(DOMAIN).po > $(DOMAIN).2po && \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
111 if cmp $(DOMAIN).1po $(DOMAIN).2po >/dev/null 2>&1; then \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
112 rm -f $(DOMAIN).1po $(DOMAIN).2po $(DOMAIN).po; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
113 else \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
114 rm -f $(DOMAIN).1po $(DOMAIN).2po $(srcdir)/$(DOMAIN).pot && \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
115 mv $(DOMAIN).po $(srcdir)/$(DOMAIN).pot; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
116 fi; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
117 else \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
118 mv $(DOMAIN).po $(srcdir)/$(DOMAIN).pot; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
119 fi; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
120 }
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
121
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
122 # This rule has no dependencies: we don't need to update $(DOMAIN).pot at
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
123 # every "make" invocation, only create it when it is missing.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
124 # Only "make $(DOMAIN).pot-update" or "make dist" will force an update.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
125 $(srcdir)/$(DOMAIN).pot:
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
126 $(MAKE) $(DOMAIN).pot-update
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
127
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
128 # This target rebuilds a PO file if $(DOMAIN).pot has changed.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
129 # Note that a PO file is not touched if it doesn't need to be changed.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
130 $(POFILES): $(srcdir)/$(DOMAIN).pot
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
131 @lang=`echo $@ | sed -e 's,.*/,,' -e 's/\.po$$//'`; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
132 test "$(srcdir)" = . && cdcmd="" || cdcmd="cd $(srcdir) && "; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
133 echo "$${cdcmd}$(MSGMERGE_UPDATE) $${lang}.po $(DOMAIN).pot"; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
134 cd $(srcdir) && $(MSGMERGE_UPDATE) $${lang}.po $(DOMAIN).pot
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
135
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
136
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
137 install: install-exec install-data
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
138 install-exec:
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
139 install-data: install-data-@USE_NLS@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
140 if test "$(PACKAGE)" = "gettext-tools"; then \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
141 $(mkinstalldirs) $(DESTDIR)$(gettextsrcdir); \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
142 for file in $(DISTFILES.common) Makevars.template; do \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
143 $(INSTALL_DATA) $(srcdir)/$$file \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
144 $(DESTDIR)$(gettextsrcdir)/$$file; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
145 done; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
146 for file in Makevars; do \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
147 rm -f $(DESTDIR)$(gettextsrcdir)/$$file; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
148 done; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
149 else \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
150 : ; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
151 fi
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
152 install-data-no: all
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
153 install-data-yes: all
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
154 $(mkinstalldirs) $(DESTDIR)$(datadir)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
155 @catalogs='$(CATALOGS)'; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
156 for cat in $$catalogs; do \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
157 cat=`basename $$cat`; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
158 lang=`echo $$cat | sed -e 's/\.gmo$$//'`; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
159 dir=$(localedir)/$$lang/LC_MESSAGES; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
160 $(mkinstalldirs) $(DESTDIR)$$dir; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
161 if test -r $$cat; then realcat=$$cat; else realcat=$(srcdir)/$$cat; fi; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
162 $(INSTALL_DATA) $$realcat $(DESTDIR)$$dir/$(DOMAIN).mo; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
163 echo "installing $$realcat as $(DESTDIR)$$dir/$(DOMAIN).mo"; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
164 for lc in '' $(EXTRA_LOCALE_CATEGORIES); do \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
165 if test -n "$$lc"; then \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
166 if (cd $(DESTDIR)$(localedir)/$$lang && LC_ALL=C ls -l -d $$lc 2>/dev/null) | grep ' -> ' >/dev/null; then \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
167 link=`cd $(DESTDIR)$(localedir)/$$lang && LC_ALL=C ls -l -d $$lc | sed -e 's/^.* -> //'`; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
168 mv $(DESTDIR)$(localedir)/$$lang/$$lc $(DESTDIR)$(localedir)/$$lang/$$lc.old; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
169 mkdir $(DESTDIR)$(localedir)/$$lang/$$lc; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
170 (cd $(DESTDIR)$(localedir)/$$lang/$$lc.old && \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
171 for file in *; do \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
172 if test -f $$file; then \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
173 ln -s ../$$link/$$file $(DESTDIR)$(localedir)/$$lang/$$lc/$$file; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
174 fi; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
175 done); \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
176 rm -f $(DESTDIR)$(localedir)/$$lang/$$lc.old; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
177 else \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
178 if test -d $(DESTDIR)$(localedir)/$$lang/$$lc; then \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
179 :; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
180 else \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
181 rm -f $(DESTDIR)$(localedir)/$$lang/$$lc; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
182 mkdir $(DESTDIR)$(localedir)/$$lang/$$lc; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
183 fi; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
184 fi; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
185 rm -f $(DESTDIR)$(localedir)/$$lang/$$lc/$(DOMAIN).mo; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
186 ln -s ../LC_MESSAGES/$(DOMAIN).mo $(DESTDIR)$(localedir)/$$lang/$$lc/$(DOMAIN).mo 2>/dev/null || \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
187 ln $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(DOMAIN).mo $(DESTDIR)$(localedir)/$$lang/$$lc/$(DOMAIN).mo 2>/dev/null || \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
188 cp -p $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(DOMAIN).mo $(DESTDIR)$(localedir)/$$lang/$$lc/$(DOMAIN).mo; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
189 echo "installing $$realcat link as $(DESTDIR)$(localedir)/$$lang/$$lc/$(DOMAIN).mo"; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
190 fi; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
191 done; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
192 done
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
193
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
194 install-strip: install
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
195
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
196 installdirs: installdirs-exec installdirs-data
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
197 installdirs-exec:
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
198 installdirs-data: installdirs-data-@USE_NLS@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
199 if test "$(PACKAGE)" = "gettext-tools"; then \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
200 $(mkinstalldirs) $(DESTDIR)$(gettextsrcdir); \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
201 else \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
202 : ; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
203 fi
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
204 installdirs-data-no:
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
205 installdirs-data-yes:
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
206 $(mkinstalldirs) $(DESTDIR)$(datadir)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
207 @catalogs='$(CATALOGS)'; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
208 for cat in $$catalogs; do \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
209 cat=`basename $$cat`; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
210 lang=`echo $$cat | sed -e 's/\.gmo$$//'`; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
211 dir=$(localedir)/$$lang/LC_MESSAGES; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
212 $(mkinstalldirs) $(DESTDIR)$$dir; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
213 for lc in '' $(EXTRA_LOCALE_CATEGORIES); do \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
214 if test -n "$$lc"; then \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
215 if (cd $(DESTDIR)$(localedir)/$$lang && LC_ALL=C ls -l -d $$lc 2>/dev/null) | grep ' -> ' >/dev/null; then \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
216 link=`cd $(DESTDIR)$(localedir)/$$lang && LC_ALL=C ls -l -d $$lc | sed -e 's/^.* -> //'`; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
217 mv $(DESTDIR)$(localedir)/$$lang/$$lc $(DESTDIR)$(localedir)/$$lang/$$lc.old; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
218 mkdir $(DESTDIR)$(localedir)/$$lang/$$lc; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
219 (cd $(DESTDIR)$(localedir)/$$lang/$$lc.old && \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
220 for file in *; do \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
221 if test -f $$file; then \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
222 ln -s ../$$link/$$file $(DESTDIR)$(localedir)/$$lang/$$lc/$$file; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
223 fi; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
224 done); \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
225 rm -f $(DESTDIR)$(localedir)/$$lang/$$lc.old; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
226 else \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
227 if test -d $(DESTDIR)$(localedir)/$$lang/$$lc; then \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
228 :; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
229 else \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
230 rm -f $(DESTDIR)$(localedir)/$$lang/$$lc; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
231 mkdir $(DESTDIR)$(localedir)/$$lang/$$lc; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
232 fi; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
233 fi; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
234 fi; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
235 done; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
236 done
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
237
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
238 # Define this as empty until I found a useful application.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
239 installcheck:
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
240
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
241 uninstall: uninstall-exec uninstall-data
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
242 uninstall-exec:
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
243 uninstall-data: uninstall-data-@USE_NLS@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
244 if test "$(PACKAGE)" = "gettext-tools"; then \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
245 for file in $(DISTFILES.common) Makevars.template; do \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
246 rm -f $(DESTDIR)$(gettextsrcdir)/$$file; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
247 done; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
248 else \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
249 : ; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
250 fi
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
251 uninstall-data-no:
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
252 uninstall-data-yes:
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
253 catalogs='$(CATALOGS)'; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
254 for cat in $$catalogs; do \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
255 cat=`basename $$cat`; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
256 lang=`echo $$cat | sed -e 's/\.gmo$$//'`; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
257 for lc in LC_MESSAGES $(EXTRA_LOCALE_CATEGORIES); do \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
258 rm -f $(DESTDIR)$(localedir)/$$lang/$$lc/$(DOMAIN).mo; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
259 done; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
260 done
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
261
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
262 check: all
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
263
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
264 info dvi ps pdf html tags TAGS ctags CTAGS ID:
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
265
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
266 mostlyclean:
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
267 rm -f remove-potcdate.sed
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
268 rm -f stamp-poT
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
269 rm -f core core.* $(DOMAIN).po $(DOMAIN).1po $(DOMAIN).2po *.new.po
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
270 rm -fr *.o
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
271
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
272 clean: mostlyclean
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
273
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
274 distclean: clean
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
275 rm -f Makefile Makefile.in POTFILES *.mo
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
276
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
277 maintainer-clean: distclean
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
278 @echo "This command is intended for maintainers to use;"
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
279 @echo "it deletes files that may require special tools to rebuild."
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
280 rm -f stamp-po $(GMOFILES)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
281
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
282 distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
283 dist distdir:
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
284 $(MAKE) update-po
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
285 @$(MAKE) dist2
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
286 # This is a separate target because 'update-po' must be executed before.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
287 dist2: $(DISTFILES)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
288 dists="$(DISTFILES)"; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
289 if test "$(PACKAGE)" = "gettext-tools"; then \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
290 dists="$$dists Makevars.template"; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
291 fi; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
292 if test -f $(srcdir)/ChangeLog; then \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
293 dists="$$dists ChangeLog"; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
294 fi; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
295 for i in 0 1 2 3 4 5 6 7 8 9; do \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
296 if test -f $(srcdir)/ChangeLog.$$i; then \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
297 dists="$$dists ChangeLog.$$i"; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
298 fi; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
299 done; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
300 if test -f $(srcdir)/LINGUAS; then dists="$$dists LINGUAS"; fi; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
301 for file in $$dists; do \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
302 if test -f $$file; then \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
303 cp -p $$file $(distdir); \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
304 else \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
305 cp -p $(srcdir)/$$file $(distdir); \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
306 fi; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
307 done
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
308
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
309 update-po: Makefile
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
310 $(MAKE) $(DOMAIN).pot-update
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
311 test -z "$(UPDATEPOFILES)" || $(MAKE) $(UPDATEPOFILES)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
312 $(MAKE) update-gmo
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
313
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
314 # General rule for updating PO files.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
315
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
316 .nop.po-update:
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
317 @lang=`echo $@ | sed -e 's/\.po-update$$//'`; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
318 if test "$(PACKAGE)" = "gettext-tools"; then PATH=`pwd`/../src:$$PATH; fi; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
319 tmpdir=`pwd`; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
320 echo "$$lang:"; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
321 test "$(srcdir)" = . && cdcmd="" || cdcmd="cd $(srcdir) && "; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
322 echo "$${cdcmd}$(MSGMERGE) $$lang.po $(DOMAIN).pot -o $$lang.new.po"; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
323 cd $(srcdir); \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
324 if $(MSGMERGE) $$lang.po $(DOMAIN).pot -o $$tmpdir/$$lang.new.po; then \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
325 if cmp $$lang.po $$tmpdir/$$lang.new.po >/dev/null 2>&1; then \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
326 rm -f $$tmpdir/$$lang.new.po; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
327 else \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
328 if mv -f $$tmpdir/$$lang.new.po $$lang.po; then \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
329 :; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
330 else \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
331 echo "msgmerge for $$lang.po failed: cannot move $$tmpdir/$$lang.new.po to $$lang.po" 1>&2; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
332 exit 1; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
333 fi; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
334 fi; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
335 else \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
336 echo "msgmerge for $$lang.po failed!" 1>&2; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
337 rm -f $$tmpdir/$$lang.new.po; \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
338 fi
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
339
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
340 $(DUMMYPOFILES):
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
341
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
342 update-gmo: Makefile $(GMOFILES)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
343 @:
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
344
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
345 Makefile: Makefile.in.in $(top_builddir)/config.status @POMAKEFILEDEPS@
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
346 cd $(top_builddir) \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
347 && CONFIG_FILES=$(subdir)/$@.in CONFIG_HEADERS= \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
348 $(SHELL) ./config.status
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
349
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
350 force:
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
351
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
352 # Tell versions [3.59,3.63) of GNU make not to export all variables.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
353 # Otherwise a system limit (for SysV at least) may be exceeded.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
354 .NOEXPORT: