* cfgcleanup.c (merge_memattrs): Look at the value of MEM_SIZE,
[official-gcc.git] / libcpp / Makefile.in
blob58904149cf63ebed4218dd7a7826ffa699f5fc9b
1 # @configure_input@
2 # Makefile for libcpp. Run 'configure' to generate Makefile from Makefile.in
4 # Copyright (C) 2004 Free Software Foundation, Inc.
6 #This file is part of libcpp.
8 #libcpp is free software; you can redistribute it and/or modify
9 #it under the terms of the GNU General Public License as published by
10 #the Free Software Foundation; either version 2, or (at your option)
11 #any later version.
13 #libcpp is distributed in the hope that it will be useful,
14 #but WITHOUT ANY WARRANTY; without even the implied warranty of
15 #MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 #GNU General Public License for more details.
18 #You should have received a copy of the GNU General Public License
19 #along with libcpp; see the file COPYING. If not, write to
20 #the Free Software Foundation, 59 Temple Place - Suite 330,
21 #Boston MA 02111-1307, USA.
23 @SET_MAKE@
25 srcdir = @srcdir@
26 top_builddir = .
27 VPATH = @srcdir@
28 INSTALL = @INSTALL@
29 AR = ar
30 ARFLAGS = cru
31 ACLOCAL = @ACLOCAL@
32 AUTOCONF = @AUTOCONF@
33 AUTOHEADER = @AUTOHEADER@
34 CATALOGS = @CATALOGS@
35 CC = @CC@
36 CFLAGS = @CFLAGS@
37 CPP = @CPP@
38 CPPFLAGS = @CPPFLAGS@
39 EXEEXT = @EXEEXT@
40 GMSGFMT = @GMSGFMT@
41 INCINTL = @INCINTL@
42 INSTALL_DATA = @INSTALL_DATA@
43 INSTALL_PROGRAM = @INSTALL_PROGRAM@
44 INSTALL_SCRIPT = @INSTALL_SCRIPT@
45 LDFLAGS = @LDFLAGS@
46 LIBICONV = @LIBICONV@
47 LIBINTL = @LIBINTL@
48 PACKAGE = @PACKAGE@
49 RANLIB = @RANLIB@
50 SHELL = @SHELL@
51 USED_CATALOGS = @USED_CATALOGS@
52 XGETTEXT = @XGETTEXT@
54 datadir = @datadir@
55 exec_prefix = @prefix@
56 libdir = @libdir@
57 localedir = $(datadir)/locale
58 prefix = @prefix@
60 MSGMERGE = msgmerge
61 mkinstalldirs = $(SHELL) $(srcdir)/../mkinstalldirs
62 DEFS = -DLOCALEDIR="\"$(localedir)\""
63 INCLUDES = -I$(srcdir) -I. -I$(srcdir)/../include @INCINTL@ \
64 -I$(srcdir)/include
66 libcpp_a_OBJS = charset.o directives.o errors.o expr.o files.o \
67 identifiers.o init.o lex.o line-map.o macro.o mkdeps.o \
68 pch.o symtab.o traditional.o
69 makedepend_OBJS = makedepend.o
71 libcpp_a_SOURCES = charset.c directives.c errors.c expr.c files.c \
72 identifiers.c init.c lex.c line-map.c macro.c mkdeps.c \
73 pch.c symtab.c traditional.c
75 all: libcpp.a makedepend$(EXEEXT) $(USED_CATALOGS)
77 .SUFFIXES:
78 .SUFFIXES: .c .gmo .o .obj .po .pox
80 libcpp.a: $(libcpp_a_OBJS)
81 -rm -f libcpp.a
82 $(AR) $(ARFLAGS) libcpp.a $(libcpp_a_OBJS)
83 $(RANLIB) libcpp.a
85 makedepend$(EXEEXT): $(makedepend_OBJS) libcpp.a ../libiberty/libiberty.a
86 @rm -f makedepend$(EXEEXT)
87 $(CC) $(CFLAGS) $(LDFLAGS) -o makedepend$(EXEEXT) \
88 $(makedepend_OBJS) libcpp.a ../libiberty/libiberty.a \
89 $(LIBINTL) $(LIBICONV)
91 # Rules to rebuild the configuration
93 Makefile: $(srcdir)/Makefile.in config.status
94 $(SHELL) ./config.status Makefile
96 config.status: $(srcdir)/configure
97 $(SHELL) ./config.status --recheck
99 $(srcdir)/configure: @MAINT@ $(srcdir)/aclocal.m4
100 cd $(srcdir) && $(AUTOCONF)
102 $(srcdir)/aclocal.m4: @MAINT@ $(srcdir)/../config/acx.m4 \
103 $(srcdir)/../config/gettext.m4 $(srcdir)/configure.ac
104 cd $(srcdir) && $(ACLOCAL) -I ../config
106 config.h: stamp-h1
107 test -f config.h || (rm -f stamp-h1 && $(MAKE) stamp-h1)
109 stamp-h1: $(srcdir)/config.in config.status
110 -rm -f stamp-h1
111 $(SHELL) ./config.status config.h
113 $(srcdir)/config.in: @MAINT@ $(srcdir)/configure
114 cd $(srcdir) && $(AUTOHEADER)
115 -rm -f stamp-h1
118 # Installation rules and other phony targets
120 # These rule has to look for .gmo modules in both srcdir and
121 # the cwd, and has to check that we actually have a catalog
122 # for each language, in case they weren't built or included
123 # with the distribution.
124 installdirs:
125 @$(mkinstalldirs) $(DESTDIR)$(datadir); \
126 cats="$(CATALOGS)"; for cat in $$cats; do \
127 lang=`basename $$cat | sed 's/\.gmo$$//'`; \
128 if [ -f $$cat ] || [ -f $(srcdir)/$$cat ]; then \
129 dir=$(localedir)/$$lang/LC_MESSAGES; \
130 $(mkinstalldirs) $(DESTDIR)$$dir || exit 1; \
131 fi; \
132 done
134 install-strip install: all installdirs
135 cats="$(CATALOGS)"; for cat in $$cats; do \
136 lang=`basename $$cat | sed 's/\.gmo$$//'`; \
137 if [ -f $$cat ]; then :; \
138 elif [ -f $(srcdir)/$$cat ]; then cat=$(srcdir)/$$cat; \
139 else continue; \
140 fi; \
141 dir=$(localedir)/$$lang/LC_MESSAGES; \
142 echo $(INSTALL_DATA) $$cat $(DESTDIR)$$dir/$(PACKAGE).mo; \
143 $(INSTALL_DATA) $$cat $(DESTDIR)$$dir/$(PACKAGE).mo; \
144 done
146 mostlyclean:
147 -rm -f *.o
149 clean: mostlyclean
150 -rm -f makedepend$(EXEEXT) libcpp.a $(srcdir)/autom4te.cache
152 distclean: clean
153 -rm -f config.h stamp-h1 config.status config.cache config.log \
154 configure.lineno configure.status.lineno Makefile
156 maintainer-clean: distclean
157 @echo "This command is intended for maintainers to use"
158 @echo "it deletes files that may require special tools to rebuild."
159 -rm -f $(srcdir)/configure $(srcdir)/aclocal.m4
161 check:
162 installcheck:
163 dvi:
164 html:
165 info:
166 install-info:
167 install-man:
169 update-po: $(CATALOGS:.gmo=.pox)
171 .PHONY: installdirs install install-strip mostlyclean clean distclean \
172 maintainer-clean check installcheck dvi html info install-info \
173 install-man update-po
175 # Implicit rules and I18N
177 .c.o:
178 $(CC) $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) -c $<
180 # N.B. We do not attempt to copy these into $(srcdir).
181 .po.gmo:
182 -test -d po || mkdir po
183 $(GMSGFMT) --statistics -o $@ $<
185 # The new .po has to be gone over by hand, so we deposit it into
186 # build/po with a different extension.
187 # If build/po/$(PACKAGE).pot exists, use it (it was just created),
188 # else use the one in srcdir.
189 .po.pox:
190 -test -d po || mkdir po
191 $(MSGMERGE) $< `if test -f po/$(PACKAGE).pot; \
192 then echo po/$(PACKAGE).pot; \
193 else echo $(srcdir)/po/$(PACKAGE).pot; fi` -o $@
195 # Rule for regenerating the message template.
196 po/$(PACKAGE).pot: $(libcpp_a_SOURCES)
197 -test -d $(srcdir)/po || mkdir $(srcdir)/po
198 $(XGETTEXT) --default-domain=$(PACKAGE) \
199 --keyword=cpp_error,3 --keyword=cpp_errno,3 \
200 --keyword=cpp_error_with_line,5 \
201 --copyright-holder="Free Software Foundation, Inc." \
202 --msgid-bugs-address="http://gcc.gnu.org/bugs.html" \
203 --language=c -o po/$(PACKAGE).pot $^
206 # Tell versions [3.59,3.63) of GNU make to not export all variables.
207 # Otherwise a system limit (for SysV at least) may be exceeded.
208 .NOEXPORT:
210 # Dependencies
212 top_srcdir = $(srcdir)/..
213 top_incdir = $(srcdir)/../include
214 libcpp_incdir = $(srcdir)/../libcpp/include
216 COMMON_DEPS = config.h $(srcdir)/system.h $(srcdir)/internal.h \
217 $(top_incdir)/libiberty.h $(top_incdir)/ansidecl.h \
218 $(top_incdir)/filenames.h $(top_incdir)/safe-ctype.h \
219 $(libcpp_incdir)/symtab.h $(top_incdir)/obstack.h \
220 $(libcpp_incdir)/line-map.h $(libcpp_incdir)/cpplib.h \
221 $(libcpp_incdir)/cpp-id-data.h $(top_incdir)/getopt.h
223 charset.o: $(srcdir)/charset.c $(COMMON_DEPS) $(srcdir)/ucnid.h
224 directives.o: $(srcdir)/directives.c $(COMMON_DEPS) $(libcpp_incdir)/mkdeps.h
225 errors.o: $(srcdir)/errors.c $(COMMON_DEPS)
226 expr.o: $(srcdir)/expr.c $(COMMON_DEPS)
228 files.o: $(srcdir)/files.c $(COMMON_DEPS) $(libcpp_incdir)/mkdeps.h \
229 $(top_incdir)/hashtab.h $(top_incdir)/md5.h
231 identifiers.o: $(srcdir)/identifiers.c $(COMMON_DEPS)
232 init.o: $(srcdir)/init.c $(COMMON_DEPS) $(libcpp_incdir)/mkdeps.h
233 lex.o: $(srcdir)/lex.c $(COMMON_DEPS)
234 line-map.o: $(srcdir)/line-map.c $(COMMON_DEPS)
235 macro.o: $(srcdir)/macro.c $(COMMON_DEPS)
236 makedepend.o: $(srcdir)/makedepend.c $(COMMON_DEPS)
237 mkdeps.o: $(srcdir)/mkdeps.c $(COMMON_DEPS)
239 pch.o: $(srcdir)/pch.c $(COMMON_DEPS) \
240 $(top_incdir)/hashtab.h $(libcpp_incdir)/mkdeps.h
242 symtab.o: $(srcdir)/symtab.c $(COMMON_DEPS)
243 traditional.o: $(srcdir)/traditional.c $(COMMON_DEPS)