home *** CD-ROM | disk | FTP | other *** search
/ Geek Gadgets 1 / ADE-1.bin / ade-dist / id-utils-3.2-src.tgz / tar.out / fsf / id-utils / intl / Makefile.in < prev    next >
Makefile  |  1996-09-28  |  6KB  |  193 lines

  1. # Makefile for directory with message catalog handling in GNU NLS Utilities.
  2. # Copyright (C) 1995, 1996 Free Software Foundation, Inc.
  3. #
  4. # This program is free software; you can redistribute it and/or modify
  5. # it under the terms of the GNU General Public License as published by
  6. # the Free Software Foundation; either version 2, or (at your option)
  7. # any later version.
  8. #
  9. # This program is distributed in the hope that it will be useful,
  10. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  12. # GNU General Public License for more details.
  13. #
  14. # You should have received a copy of the GNU General Public License
  15. # along with this program; if not, write to the Free Software
  16. # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
  17.  
  18. PACKAGE = @PACKAGE@
  19. VERSION = @VERSION@
  20.  
  21. SHELL = /bin/sh
  22.  
  23. srcdir = @srcdir@
  24. top_srcdir = @top_srcdir@
  25. VPATH = @srcdir@
  26.  
  27. prefix = @prefix@
  28. exec_prefix = @exec_prefix@
  29. transform = @program_transform_name@
  30. libdir = $(prefix)/lib
  31. includedir = $(prefix)/include
  32. datadir = $(prefix)/@DATADIRNAME@
  33. localedir = $(datadir)/locale
  34. gnulocaledir = $(prefix)/share/locale
  35. gettextsrcdir = @datadir@/gettext/intl
  36. aliaspath = $(localedir):.
  37. subdir = intl
  38.  
  39. INSTALL = @INSTALL@
  40. INSTALL_DATA = @INSTALL_DATA@
  41. MKINSTALLDIRS = @MKINSTALLDIRS@
  42.  
  43. AR = ar
  44. CC = @CC@
  45. RANLIB = @RANLIB@
  46.  
  47. DEFS = -DLOCALEDIR=\"$(localedir)\" -DGNULOCALEDIR=\"$(gnulocaledir)\" \
  48. -DLOCALE_ALIAS_PATH=\"$(aliaspath)\" @DEFS@
  49. CFLAGS = @CFLAGS@
  50.  
  51. COMPILE = $(CC) -c $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) $(XCFLAGS)
  52.  
  53. HEADERS = $(COMHDRS) libgettext.h loadinfo.h
  54. COMHDRS = gettext.h gettextP.h hash-string.h
  55. SOURCES = $(COMSRCS) intl-compat.c cat-compat.c
  56. COMSRCS = bindtextdom.c dcgettext.c dgettext.c gettext.c \
  57. finddomain.c loadmsgcat.c localealias.c textdomain.c l10nflist.c \
  58. explodename.c
  59. OBJECTS = @INTLOBJS@ bindtextdom.o dcgettext.o dgettext.o gettext.o \
  60. finddomain.o loadmsgcat.o localealias.o textdomain.o l10nflist.o \
  61. explodename.o
  62. CATOBJS = cat-compat.o ../po/cat-id-tbl.o
  63. GETTOBJS = intl-compat.o
  64. DISTFILES.common = ChangeLog Makefile.in linux-msg.sed po2tbl.sed.in \
  65. xopen-msg.sed $(HEADERS) $(SOURCES)
  66. DISTFILES.normal = VERSION
  67. DISTFILES.gettext = libintl.glibc intlh.inst.in
  68.  
  69. .SUFFIXES:
  70. .SUFFIXES: .c .o
  71. .c.o:
  72.     $(COMPILE) $<
  73.  
  74. INCLUDES = -I.. -I. -I$(top_srcdir)/intl -I$(top_srcdir)/lib
  75.  
  76. all: all-@USE_INCLUDED_LIBINTL@
  77.  
  78. all-yes: libintl.a intlh.inst
  79. all-no:
  80.  
  81. libintl.a: $(OBJECTS)
  82.     rm -f $@
  83.     $(AR) cru $@ $(OBJECTS)
  84.     $(RANLIB) $@
  85.  
  86. ../po/cat-id-tbl.o: ../po/cat-id-tbl.c $(top_srcdir)/po/$(PACKAGE).pot
  87.     cd ../po && $(MAKE) cat-id-tbl.o
  88.  
  89. check: all
  90.  
  91. # This installation goal is only used in GNU gettext.  Packages which
  92. # only use the library should use install instead.
  93.  
  94. # We must not install the libintl.h/libintl.a files if we are on a
  95. # system which has the gettext() function in its C library or in a
  96. # separate library or use the catgets interface.  A special case is
  97. # where configure found a previously installed GNU gettext library.
  98. # If you want to use the one which comes with this version of the
  99. # package, you have to use `configure --with-included-gettext'.
  100. install: all
  101.     if test "$(PACKAGE)" = "gettext"; then \
  102.       if test -r $(MKINSTALLDIRS); then \
  103.         $(MKINSTALLDIRS) $(libdir) $(includedir) $(gettextsrcdir); \
  104.       else \
  105.         $(top_srcdir)/mkinstalldirs $(libdir) $(includedir) \
  106.           $(gettextsrcdir); \
  107.       fi; \
  108.       if test '@INTLOBJS@' = '$(GETTOBJS)'; then \
  109.         $(INSTALL_DATA) intlh.inst $(includedir)/libintl.h; \
  110.         $(INSTALL_DATA) libintl.a $(libdir)/libintl.a; \
  111.       fi; \
  112.       $(INSTALL_DATA) VERSION $(gettextsrcdir)/VERSION; \
  113.       cd $(srcdir) && \
  114.       for file in $(DISTFILES.common); do \
  115.         $(INSTALL_DATA) $$file $(gettextsrcdir)/$$file; \
  116.       done; \
  117.     else \
  118.       : ; \
  119.     fi
  120.  
  121. # Define this as empty until I found a useful application.
  122. installcheck:
  123.  
  124. uninstall:
  125.     for file in $(DISTFILES); do \
  126.       rm -f $(gettextsrcdir)/intl-$$file; \
  127.     done
  128.  
  129. info dvi:
  130.  
  131. $(OBJECTS): ../config.h libgettext.h
  132. bindtextdom.o finddomain.o loadmsgcat.o: gettextP.h gettext.h loadinfo.h
  133. dcgettext.o: gettextP.h gettext.h hash-string.h loadinfo.h
  134.  
  135. tags: TAGS
  136.  
  137. TAGS: $(HEADERS) $(SOURCES)
  138.     here=`pwd`; cd $(srcdir) && etags -o $$here/TAGS $(HEADERS) $(SOURCES)
  139.  
  140. id: ID
  141.  
  142. ID: $(HEADERS) $(SOURCES)
  143.     here=`pwd`; cd $(srcdir) && mkid -f$$here/ID $(HEADERS) $(SOURCES)
  144.  
  145.  
  146. mostlyclean:
  147.     rm -f *.a *.o core core.*
  148.  
  149. clean: mostlyclean
  150.  
  151. distclean: clean
  152.     rm -f Makefile ID TAGS po2msg.sed po2tbl.sed libintl.h
  153.  
  154. maintainer-clean: distclean
  155.     @echo "This command is intended for maintainers to use;"
  156.     @echo "it deletes files that may require special tools to rebuild."
  157.  
  158.  
  159. # GNU gettext needs not contain the file `VERSION' but contains some
  160. # other files which should not be distributed in other packages.
  161. distdir = ../$(PACKAGE)-$(VERSION)/$(subdir)
  162. dist distdir: Makefile $(DISTFILES)
  163.     if test "$(PACKAGE)" = gettext; then \
  164.       additional="$(DISTFILES.gettext)"; \
  165.     else \
  166.       additional="$(DISTFILES.normal)"; \
  167.     fi; \
  168.     for file in $(DISTFILES.common) $$additional; do \
  169.       ln $(srcdir)/$$file $(distdir) 2> /dev/null \
  170.         || cp -p $(srcdir)/$$file $(distdir); \
  171.     done
  172.  
  173. dist-libc:
  174.     tar zcvf intl-glibc.tar.gz $(COMSRCS) $(COMHDRS) libintl.h.glibc
  175.  
  176. Makefile: Makefile.in ../config.status
  177.     cd .. \
  178.       && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
  179.  
  180. # The dependency for intlh.inst is different in gettext and all other
  181. # packages.  Because we cannot you GNU make features we have to solve
  182. # the problem while rewriting Makefile.in.
  183. @GT_YES@intlh.inst: intlh.inst.in ../config.status
  184. @GT_YES@    cd .. \
  185. @GT_YES@    && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= \
  186. @GT_YES@      $(SHELL) ./config.status
  187. @GT_NO@.PHONY: intlh.inst
  188. @GT_NO@intlh.inst:
  189.  
  190. # Tell versions [3.59,3.63) of GNU make not to export all variables.
  191. # Otherwise a system limit (for SysV at least) may be exceeded.
  192. .NOEXPORT:
  193.