~ubuntu-branches/ubuntu/dapper/gnome-screensaver/dapper

« back to all changes in this revision

Viewing changes to po/Makefile.in.in

  • Committer: Bazaar Package Importer
  • Author(s): Oliver Grawert
  • Date: 2005-10-10 00:18:18 UTC
  • Revision ID: james.westby@ubuntu.com-20051010001818-3mujs05r8rht7xi1
Tags: upstream-0.0.15
ImportĀ upstreamĀ versionĀ 0.0.15

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# Makefile for program source directory in GNU NLS utilities package.
 
2
# Copyright (C) 1995, 1996, 1997 by Ulrich Drepper <drepper@gnu.ai.mit.edu>
 
3
#
 
4
# This file file be copied and used freely without restrictions.  It can
 
5
# be used in projects which are not available under the GNU Public License
 
6
# but which still want to provide support for the GNU gettext functionality.
 
7
# Please note that the actual code is *not* freely available.
 
8
#
 
9
# - Modified by Owen Taylor <otaylor@redhat.com> to use GETTEXT_PACKAGE
 
10
#   instead of PACKAGE and to look for po2tbl in ./ not in intl/
 
11
#
 
12
# - Modified by jacob berkman <jacob@ximian.com> to install
 
13
#   Makefile.in.in and po2tbl.sed.in for use with glib-gettextize
 
14
#
 
15
# - Modified by Rodney Dawes <dobey@novell.com> for use with intltool
 
16
#
 
17
# We have the following line for use by intltoolize:
 
18
# INTLTOOL_MAKEFILE
 
19
 
 
20
GETTEXT_PACKAGE = @GETTEXT_PACKAGE@
 
21
PACKAGE = @PACKAGE@
 
22
VERSION = @VERSION@
 
23
 
 
24
SHELL = /bin/sh
 
25
@SET_MAKE@
 
26
 
 
27
srcdir = @srcdir@
 
28
top_srcdir = @top_srcdir@
 
29
top_builddir = ..
 
30
VPATH = @srcdir@
 
31
 
 
32
prefix = @prefix@
 
33
exec_prefix = @exec_prefix@
 
34
datadir = @datadir@
 
35
datarootdir = @datarootdir@
 
36
libdir = @libdir@
 
37
localedir = $(libdir)/locale
 
38
gnulocaledir = $(datadir)/locale
 
39
gettextsrcdir = $(datadir)/glib-2.0/gettext/po
 
40
subdir = po
 
41
install_sh = @install_sh@
 
42
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
 
43
 
 
44
INSTALL = @INSTALL@
 
45
INSTALL_DATA = @INSTALL_DATA@
 
46
 
 
47
CC = @CC@
 
48
GMSGFMT = @GMSGFMT@
 
49
MSGFMT = @MSGFMT@
 
50
XGETTEXT = @XGETTEXT@
 
51
INTLTOOL_UPDATE = @INTLTOOL_UPDATE@
 
52
INTLTOOL_EXTRACT = @INTLTOOL_EXTRACT@
 
53
MSGMERGE = INTLTOOL_EXTRACT=$(INTLTOOL_EXTRACT) srcdir=$(srcdir) $(INTLTOOL_UPDATE) --gettext-package $(GETTEXT_PACKAGE) --dist
 
54
GENPOT   = INTLTOOL_EXTRACT=$(INTLTOOL_EXTRACT) srcdir=$(srcdir) $(INTLTOOL_UPDATE) --gettext-package $(GETTEXT_PACKAGE) --pot
 
55
 
 
56
DEFS = @DEFS@
 
57
CFLAGS = @CFLAGS@
 
58
CPPFLAGS = @CPPFLAGS@
 
59
 
 
60
INCLUDES = -I.. -I$(top_srcdir)/intl
 
61
 
 
62
COMPILE = $(CC) -c $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) $(XCFLAGS)
 
63
 
 
64
SOURCES = 
 
65
POFILES = @POFILES@
 
66
GMOFILES = @GMOFILES@
 
67
DISTFILES = ChangeLog Makefile.in.in POTFILES.in \
 
68
$(POFILES) $(SOURCES)
 
69
EXTRA_DISTFILES = POTFILES.skip Makevars LINGUAS
 
70
 
 
71
POTFILES = \
 
72
 
 
73
CATALOGS = @CATALOGS@
 
74
CATOBJEXT = @CATOBJEXT@
 
75
 
 
76
.SUFFIXES:
 
77
.SUFFIXES: .c .o .po .pox .gmo .mo .msg .cat
 
78
 
 
79
.c.o:
 
80
        $(COMPILE) $<
 
81
 
 
82
.po.pox:
 
83
        $(MAKE) $(GETTEXT_PACKAGE).pot
 
84
        $(MSGMERGE) $< $(GETTEXT_PACKAGE).pot -o $*.pox
 
85
 
 
86
.po.mo:
 
87
        $(MSGFMT) -o $@ $<
 
88
 
 
89
.po.gmo:
 
90
        file=`echo $* | sed 's,.*/,,'`.gmo \
 
91
          && rm -f $$file && $(GMSGFMT) -o $$file $<
 
92
 
 
93
.po.cat:
 
94
        sed -f ../intl/po2msg.sed < $< > $*.msg \
 
95
          && rm -f $@ && gencat $@ $*.msg
 
96
 
 
97
 
 
98
all: all-@USE_NLS@
 
99
 
 
100
all-yes: $(CATALOGS)
 
101
all-no:
 
102
 
 
103
$(GETTEXT_PACKAGE).pot: $(POTFILES)
 
104
        $(GENPOT)
 
105
 
 
106
install: install-exec install-data
 
107
install-exec:
 
108
install-data: install-data-@USE_NLS@
 
109
install-data-no: all
 
110
install-data-yes: all
 
111
        if test -n "$(MKINSTALLDIRS)"; then \
 
112
          $(MKINSTALLDIRS) $(DESTDIR)$(datadir); \
 
113
        else \
 
114
          $(SHELL) $(top_srcdir)/mkinstalldirs $(DESTDIR)$(datadir); \
 
115
        fi
 
116
        @catalogs='$(CATALOGS)'; \
 
117
        for cat in $$catalogs; do \
 
118
          cat=`basename $$cat`; \
 
119
          case "$$cat" in \
 
120
            *.gmo) destdir=$(gnulocaledir);; \
 
121
            *)     destdir=$(localedir);; \
 
122
          esac; \
 
123
          lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \
 
124
          dir=$(DESTDIR)$$destdir/$$lang/LC_MESSAGES; \
 
125
          if test -n "$(MKINSTALLDIRS)"; then \
 
126
            $(MKINSTALLDIRS) $$dir; \
 
127
          else \
 
128
            $(SHELL) $(top_srcdir)/mkinstalldirs $$dir; \
 
129
          fi; \
 
130
          if test -r $$cat; then \
 
131
            $(INSTALL_DATA) $$cat $$dir/$(GETTEXT_PACKAGE).mo; \
 
132
            echo "installing $$cat as $$dir/$(GETTEXT_PACKAGE).mo"; \
 
133
          else \
 
134
            $(INSTALL_DATA) $(srcdir)/$$cat $$dir/$(GETTEXT_PACKAGE).mo; \
 
135
            echo "installing $(srcdir)/$$cat as" \
 
136
                 "$$dir/$(GETTEXT_PACKAGE).mo"; \
 
137
          fi; \
 
138
          if test -r $$cat.m; then \
 
139
            $(INSTALL_DATA) $$cat.m $$dir/$(GETTEXT_PACKAGE).mo.m; \
 
140
            echo "installing $$cat.m as $$dir/$(GETTEXT_PACKAGE).mo.m"; \
 
141
          else \
 
142
            if test -r $(srcdir)/$$cat.m ; then \
 
143
              $(INSTALL_DATA) $(srcdir)/$$cat.m \
 
144
                $$dir/$(GETTEXT_PACKAGE).mo.m; \
 
145
              echo "installing $(srcdir)/$$cat as" \
 
146
                   "$$dir/$(GETTEXT_PACKAGE).mo.m"; \
 
147
            else \
 
148
              true; \
 
149
            fi; \
 
150
          fi; \
 
151
        done
 
152
        if test "$(PACKAGE)" = "glib"; then \
 
153
          if test -n "$(MKINSTALLDIRS)"; then \
 
154
            $(MKINSTALLDIRS) $(DESTDIR)$(gettextsrcdir); \
 
155
          else \
 
156
            $(SHELL) $(top_srcdir)/mkinstalldirs $(DESTDIR)$(gettextsrcdir); \
 
157
          fi; \
 
158
          $(INSTALL_DATA) $(srcdir)/Makefile.in.in \
 
159
                          $(DESTDIR)$(gettextsrcdir)/Makefile.in.in; \
 
160
        else \
 
161
          : ; \
 
162
        fi
 
163
 
 
164
# Define this as empty until I found a useful application.
 
165
installcheck:
 
166
 
 
167
uninstall:
 
168
        catalogs='$(CATALOGS)'; \
 
169
        for cat in $$catalogs; do \
 
170
          cat=`basename $$cat`; \
 
171
          lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \
 
172
          rm -f $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(GETTEXT_PACKAGE).mo; \
 
173
          rm -f $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(GETTEXT_PACKAGE).mo.m; \
 
174
          rm -f $(DESTDIR)$(gnulocaledir)/$$lang/LC_MESSAGES/$(GETTEXT_PACKAGE).mo; \
 
175
          rm -f $(DESTDIR)$(gnulocaledir)/$$lang/LC_MESSAGES/$(GETTEXT_PACKAGE).mo.m; \
 
176
        done
 
177
        if test "$(PACKAGE)" = "glib"; then \
 
178
          rm -f $(DESTDIR)$(gettextsrcdir)/Makefile.in.in; \
 
179
        fi
 
180
 
 
181
check: all $(GETTEXT_PACKAGE).pot
 
182
 
 
183
dvi info tags TAGS ID:
 
184
 
 
185
mostlyclean:
 
186
        rm -f core core.* *.pox $(GETTEXT_PACKAGE).pot *.old.po cat-id-tbl.tmp
 
187
        rm -fr *.o
 
188
        rm -f .intltool-merge-cache
 
189
 
 
190
clean: mostlyclean
 
191
 
 
192
distclean: clean
 
193
        rm -f Makefile Makefile.in POTFILES
 
194
        rm -f *.mo *.msg *.cat *.cat.m $(GMOFILES)
 
195
 
 
196
maintainer-clean: distclean
 
197
        @echo "This command is intended for maintainers to use;"
 
198
        @echo "it deletes files that may require special tools to rebuild."
 
199
        rm -f Makefile.in.in
 
200
 
 
201
distdir = ../$(GETTEXT_PACKAGE)-$(VERSION)/$(subdir)
 
202
dist distdir: $(DISTFILES)
 
203
        dists="$(DISTFILES)"; \
 
204
        extra_dists="$(EXTRA_DISTFILES)"; \
 
205
        for file in $$extra_dists; do \
 
206
          test -f $$file && dists="$$dists $$file"; \
 
207
        done; \
 
208
        for file in $$dists; do \
 
209
          ln $(srcdir)/$$file $(distdir) 2> /dev/null \
 
210
            || cp -p $(srcdir)/$$file $(distdir); \
 
211
        done
 
212
 
 
213
update-po: Makefile
 
214
        $(MAKE) $(GETTEXT_PACKAGE).pot
 
215
        tmpdir=`pwd`; \
 
216
        catalogs='$(CATALOGS)'; \
 
217
        for cat in $$catalogs; do \
 
218
          cat=`basename $$cat`; \
 
219
          lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \
 
220
          echo "$$lang:"; \
 
221
          result="`$(MSGMERGE) -o $$tmpdir/$$lang.new.po $$lang`"; \
 
222
          if $$result; then \
 
223
            if cmp $(srcdir)/$$lang.po $$tmpdir/$$lang.new.po >/dev/null 2>&1; then \
 
224
              rm -f $$tmpdir/$$lang.new.po; \
 
225
            else \
 
226
              if mv -f $$tmpdir/$$lang.new.po $$lang.po; then \
 
227
                :; \
 
228
              else \
 
229
                echo "msgmerge for $$lang.po failed: cannot move $$tmpdir/$$lang.new.po to $$lang.po" 1>&2; \
 
230
                rm -f $$tmpdir/$$lang.new.po; \
 
231
                exit 1; \
 
232
              fi; \
 
233
            fi; \
 
234
          else \
 
235
            echo "msgmerge for $$cat failed!"; \
 
236
            rm -f $$tmpdir/$$lang.new.po; \
 
237
          fi; \
 
238
        done
 
239
 
 
240
# POTFILES is created from POTFILES.in by stripping comments, empty lines
 
241
# and Intltool tags (enclosed in square brackets), and appending a full
 
242
# relative path to them
 
243
POTFILES: POTFILES.in
 
244
        ( posrcprefix='$(top_srcdir)/'; \
 
245
          rm -f $@-t $@ \
 
246
            && (sed -e '/^#/d'                                  \
 
247
                    -e 's/^[[].*] *//'                          \
 
248
                    -e '/^[     ]*$$/d'                         \
 
249
                    -e "s@^@    $$posrcprefix@" $(srcdir)/$@.in \
 
250
                | sed -e '$$!s/$$/ \\/') > $@-t \
 
251
            && chmod a-w $@-t \
 
252
            && mv $@-t $@ )
 
253
 
 
254
Makefile: Makefile.in.in ../config.status POTFILES
 
255
        cd .. \
 
256
          && CONFIG_FILES=$(subdir)/$@.in CONFIG_HEADERS= \
 
257
               $(SHELL) ./config.status
 
258
 
 
259
# Tell versions [3.59,3.63) of GNU make not to export all variables.
 
260
# Otherwise a system limit (for SysV at least) may be exceeded.
 
261
.NOEXPORT: