1# Generated automatically from Makefile.in.in by configure. 2# Makefile for program source directory in GNU NLS utilities package. 3# Copyright (C) 1995 Free Software Foundation, Inc. 4# 5# This program is free software; you can redistribute it and/or modify 6# it under the terms of the GNU General Public License as published by 7# the Free Software Foundation; either version 2, or (at your option) 8# any later version. 9# 10# This program is distributed in the hope that it will be useful, 11# but WITHOUT ANY WARRANTY; without even the implied warranty of 12# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13# GNU General Public License for more details. 14# 15# You should have received a copy of the GNU General Public License 16# along with this program; if not, write to the Free Software 17# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 18 19PACKAGE = sharutils 20VERSION = 4.2.1 21 22SHELL = /bin/sh 23 24 25srcdir = . 26top_srcdir = .. 27 28prefix = /usr/local 29exec_prefix = ${prefix} 30datadir = $(prefix)/share 31localedir = $(datadir)/locale 32gnulocaledir = $(prefix)/share/locale 33gettextsrcdir = $(prefix)/share/gettext 34subdir = po 35 36INSTALL = /bin/install -c 37INSTALL_DATA = ${INSTALL} -m 644 38 39CC = gcc 40GENCAT = 41GMSGFMT = msgfmt 42MSGFMT = msgfmt 43XGETTEXT = xgettext 44TUPDATE = tupdate 45 46DEFS = -DHAVE_CONFIG_H 47CFLAGS = -g -O 48CPPFLAGS = 49 50INCLUDES = -I.. -I$(top_srcdir)/intl 51 52COMPILE = $(CC) -c $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) $(XCFLAGS) 53 54SOURCES = cat-id-tbl.c 55POFILES = de.po fr.po ja_JP.EUC.po nl.po pt.po sv.po 56GMOFILES = de.gmo fr.gmo ja_JP.EUC.gmo nl.gmo pt.gmo sv.gmo 57DISTFILES = ChangeLog Makefile.in.in POTFILES.in $(PACKAGE).pot \ 58stamp-cat-id $(POFILES) $(GMOFILES) $(SOURCES) 59 60POTFILES = \ 61 62CATALOGS = de.gmo fr.gmo ja_JP.EUC.gmo nl.gmo pt.gmo sv.gmo 63CATOBJEXT = .gmo 64INSTOBJEXT = .mo 65 66.SUFFIXES: 67.SUFFIXES: .c .o .po .pox .gmo .mo .msg .cat 68 69.c.o: 70 $(COMPILE) $< 71 72.po.pox: 73 $(MAKE) $(PACKAGE).pot 74 $(TUPDATE) $(srcdir)/$(PACKAGE).pot $< > $*.pox 75 76.po.mo: 77 $(MSGFMT) -o $@ $< 78 79.po.gmo: 80 file=$(srcdir)/`echo $* | sed 's,.*/,,'`.gmo \ 81 && rm -f $$file && $(GMSGFMT) -o $$file $< 82 83.po.cat: 84 sed -f ../intl/po2msg.sed < $< > $*.msg \ 85 && rm -f $@ && $(GENCAT) $@ $*.msg 86 87 88all: cat-id-tbl.c $(CATALOGS) 89 90$(PACKAGE).pot: $(POTFILES) 91 $(XGETTEXT) --default-domain=$(PACKAGE) --directory=$(top_srcdir) \ 92 --add-comments --keyword=_ --keyword=N_ \ 93 --files-from=$(srcdir)/POTFILES.in 94 if cmp -s $(PACKAGE).po $(srcdir)/$(PACKAGE).pot; then \ 95 rm -f $(PACKAGE).po; \ 96 else \ 97 rm -f $(srcdir)/$(PACKAGE).pot \ 98 && mv $(PACKAGE).po $(srcdir)/$(PACKAGE).pot; \ 99 fi 100 101cat-id-tbl.c: stamp-cat-id 102stamp-cat-id: $(PACKAGE).pot 103 rm -f cat-id-tbl.tmp.c 104 sed -f ../intl/po2tbl.sed $(srcdir)/$(PACKAGE).pot \ 105 | sed -e "s/@PACKAGE NAME@/$(PACKAGE)/" > cat-id-tbl.tmp.c 106 if cmp -s cat-id-tbl.tmp.c $(srcdir)/cat-id-tbl.c; then \ 107 rm cat-id-tbl.tmp.c; \ 108 else \ 109 echo cat-id-tbl.c changed; \ 110 rm -f $(srcdir)/cat-id-tbl.c; \ 111 mv cat-id-tbl.tmp.c $(srcdir)/cat-id-tbl.c; \ 112 fi 113 cd $(srcdir) && rm -f stamp-cat-id && echo timestamp > stamp-cat-id 114 115 116install: install-exec install-data 117install-exec: 118install-data: all 119 $(top_srcdir)/mkinstalldirs $(datadir) 120 catalogs='$(CATALOGS)'; \ 121 for cat in $$catalogs; do \ 122 if test "`echo $$cat | sed 's/.*\(\..*\)/\1/'`" = ".gmo"; then \ 123 destdir=$(gnulocaledir); \ 124 else \ 125 destdir=$(localedir); \ 126 fi; \ 127 lang=`echo $$cat | sed 's/$(CATOBJEXT)$$//'`; \ 128 dir=$$destdir/$$lang/LC_MESSAGES; \ 129 $(top_srcdir)/mkinstalldirs $$dir; \ 130 if test -r $$cat; then \ 131 $(INSTALL_DATA) $$cat $$dir/$(PACKAGE)$(INSTOBJEXT); \ 132 else \ 133 $(INSTALL_DATA) $(srcdir)/$$cat $$dir/$(PACKAGE)$(INSTOBJEXT); \ 134 fi; \ 135 done 136 137# This installation goal is only used in GNU gettext. Packages which 138# only use the library should use install instead. 139install-src: install 140 $(top_srcdir)/mkinstalldirs $(gettextsrcdir) 141 cd $(srcdir) && \ 142 $(INSTALL_DATA) Makefile.in.in $(gettextsrcdir)/po-Makefile.in.in 143 144uninstall: 145 catalogs='$(CATALOGS)'; \ 146 for cat in $$catalogs; do \ 147 lang=`echo $$cat | sed 's/$(CATOBJEXT)$$//'`; \ 148 rm -f $(localedir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT); \ 149 rm -f $(gnulocaledir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT); \ 150 done 151 rm -f $(gettextsrcdir)/po-Makefile.in.in 152 153check: all 154 155cat-id-tbl.o: ../intl/libgettext.h 156 157TAGS ID: 158 159mostlyclean: 160 rm -f core core.* *.pox $(PACKAGE).po *.old.po cat-id-tbl.tmp.c 161 162clean: mostlyclean 163 164distclean: clean 165 rm -f Makefile Makefile.in POTFILES *.mo *.msg *.cat 166 167maintainer-clean: distclean 168 @echo "This command is intended for maintainers to use;" 169 @echo "it deletes files that may require special tools to rebuild." 170 171distdir = ../$(PACKAGE)-$(VERSION)/$(subdir) 172dist dist-gettext: update-po $(DISTFILES) 173 for file in $(DISTFILES); do \ 174 ln $(srcdir)/$$file $(distdir) 2> /dev/null \ 175 || cp -p $(srcdir)/$$file $(distdir); \ 176 done 177 178update-po: Makefile 179 $(MAKE) $(PACKAGE).pot 180 cd $(srcdir); \ 181 catalogs='$(CATALOGS)'; \ 182 for cat in $$catalogs; do \ 183 lang=`echo $$cat | sed 's/$(CATOBJEXT)$$//'`; \ 184 mv $$lang.po $$lang.old.po; \ 185 if $(TUPDATE) $(PACKAGE).pot $$lang.old.po > $$lang.po; then \ 186 rm -f $$lang.old.po; \ 187 else \ 188 echo "tupdate for $$cat failed!"; \ 189 rm -f $$lang.po; \ 190 mv $$lang.old.po $$lang.po; \ 191 fi; \ 192 done 193 194POTFILES: POTFILES.in 195 ( if test 'x$(srcdir)' != 'x.'; then \ 196 posrcprefix='$(top_srcdir)/'; \ 197 else \ 198 posrcprefix="../"; \ 199 fi; \ 200 sed -e '/^#/d' -e '/^[ ]*$$/d' \ 201 -e "s@.*@ $$posrcprefix& \\\\@" \ 202 -e '$$s/\(.*\) \\/\1/' < $(srcdir)/POTFILES.in > POTFILES ) 203 204Makefile: Makefile.in.in ../config.status POTFILES 205 cd .. && CONFIG_FILES=$(subdir)/$@.in CONFIG_HEADERS= ./config.status 206 207# Tell versions [3.59,3.63) of GNU make not to export all variables. 208# Otherwise a system limit (for SysV at least) may be exceeded. 209.NOEXPORT: 210