1 [+ AutoGen5 template -*- Mode: Makefile -*-
5 # Makefile.in is generated from Makefile.tpl by 'autogen Makefile.def'.
7 # Makefile for directory with subdirs to build.
8 # Copyright (C) 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
9 # 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation
11 # This file is free software; you can redistribute it and/or modify
12 # it under the terms of the GNU General Public License as published by
13 # the Free Software Foundation; either version 2 of the License, or
14 # (at your option) any later version.
16 # This program is distributed in the hope that it will be useful,
17 # but WITHOUT ANY WARRANTY; without even the implied warranty of
18 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 # GNU General Public License for more details.
21 # You should have received a copy of the GNU General Public License
22 # along with this program; if not, write to the Free Software
23 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
26 # -------------------------------
27 # Standard Autoconf-set variables
28 # -------------------------------
31 build_alias=@build_alias@
33 host_alias=@host_alias@
35 target_alias=@target_alias@
38 program_transform_name = @program_transform_name@
41 exec_prefix = @exec_prefix@
47 libexecdir = @libexecdir@
49 sysconfdir = @sysconfdir@
50 sharedstatedir = @sharedstatedir@
51 localstatedir = @localstatedir@
53 includedir = @includedir@
54 oldincludedir = @oldincludedir@
57 man1dir = $(mandir)/man1
58 man2dir = $(mandir)/man2
59 man3dir = $(mandir)/man3
60 man4dir = $(mandir)/man4
61 man5dir = $(mandir)/man5
62 man6dir = $(mandir)/man6
63 man7dir = $(mandir)/man7
64 man8dir = $(mandir)/man8
65 man9dir = $(mandir)/man9
68 INSTALL_PROGRAM = @INSTALL_PROGRAM@
69 INSTALL_SCRIPT = @INSTALL_SCRIPT@
70 INSTALL_DATA = @INSTALL_DATA@
74 # -------------------------------------------------
75 # Miscellaneous non-standard autoconf-set variables
76 # -------------------------------------------------
78 # The file containing GCC's version number.
79 gcc_version_trigger = @gcc_version_trigger@
80 gcc_version = @gcc_version@
82 # The gcc driver likes to know the arguments it was configured with.
83 TOPLEVEL_CONFIGURE_ARGUMENTS=@TOPLEVEL_CONFIGURE_ARGUMENTS@
85 gxx_include_dir = @gxx_include_dir@
86 libstdcxx_incdir = @libstdcxx_incdir@
89 build_tooldir = @build_tooldir@
91 # Directory in which the compiler finds executables, libraries, etc.
92 libsubdir = $(libdir)/gcc/$(target_alias)/$(gcc_version)
95 # This is the name of the environment variable used for the path to
97 RPATH_ENVVAR = @RPATH_ENVVAR@
99 # This is set by configure to REALLY_SET_LIB_PATH if --enable-shared
101 SET_LIB_PATH = @SET_LIB_PATH@
103 # configure.in sets SET_LIB_PATH to this if --enable-shared was used.
104 # Some platforms don't like blank entries, so we remove duplicate,
105 # leading and trailing colons.
106 REALLY_SET_LIB_PATH = \
107 $(RPATH_ENVVAR)=`echo "$(HOST_LIB_PATH):$(TARGET_LIB_PATH):$$$(RPATH_ENVVAR)" | sed 's,::*,:,g;s,^:*,,;s,:*$$,,'`; export $(RPATH_ENVVAR);
109 # This is the list of directories to be built for the build system.
110 BUILD_CONFIGDIRS = libiberty libbanshee
111 # Build programs are put under this directory.
112 BUILD_SUBDIR = @build_subdir@
113 # This is set by the configure script to the arguments to use when configuring
114 # directories built for the build system.
115 BUILD_CONFIGARGS = @build_configargs@
117 # This is the list of variables to export in the environment when
118 # configuring any subdirectory. It must also be exported whenever
119 # recursing into a build directory in case that directory's Makefile
122 FLEX="$(FLEX)"; export FLEX; \
123 LEX="$(LEX)"; export LEX; \
124 BISON="$(BISON)"; export BISON; \
125 YACC="$(YACC)"; export YACC; \
126 M4="$(M4)"; export M4; \
127 MAKEINFO="$(MAKEINFO)"; export MAKEINFO;
129 # This is the list of variables to export in the environment when
130 # configuring subdirectories for the build system.
133 AR="$(AR_FOR_BUILD)"; export AR; \
134 AS="$(AS_FOR_BUILD)"; export AS; \
135 CC="$(CC_FOR_BUILD)"; export CC; \
136 CFLAGS="$(CFLAGS_FOR_BUILD)"; export CFLAGS; \
137 CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
138 CXX="$(CXX_FOR_BUILD)"; export CXX; \
139 CXXFLAGS="$(CXXFLAGS_FOR_BUILD)"; export CXXFLAGS; \
140 GCJ="$(GCJ_FOR_BUILD)"; export GCJ; \
141 GFORTRAN="$(GFORTRAN_FOR_BUILD)"; export GFORTRAN; \
142 DLLTOOL="$(DLLTOOL_FOR_BUILD)"; export DLLTOOL; \
143 LD="$(LD_FOR_BUILD)"; export LD; \
144 LDFLAGS="$(LDFLAGS_FOR_BUILD)"; export LDFLAGS; \
145 NM="$(NM_FOR_BUILD)"; export NM; \
146 RANLIB="$(RANLIB_FOR_BUILD)"; export RANLIB; \
147 WINDRES="$(WINDRES_FOR_BUILD)"; export WINDRES;
149 # This is the list of directories to built for the host system.
150 SUBDIRS = @configdirs@
151 # This is set by the configure script to the arguments to use when configuring
152 # directories built for the host system.
153 HOST_CONFIGARGS = @host_configargs@
154 # This is the list of variables to export in the environment when
155 # configuring subdirectories for the host system.
158 CC="$(CC)"; export CC; \
159 CFLAGS="$(CFLAGS)"; export CFLAGS; \
160 CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
161 CXX="$(CXX)"; export CXX; \
162 CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
163 AR="$(AR)"; export AR; \
164 AS="$(AS)"; export AS; \
165 CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
166 DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
167 LD="$(LD)"; export LD; \
168 LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
169 NM="$(NM)"; export NM; \
170 RANLIB="$(RANLIB)"; export RANLIB; \
171 WINDRES="$(WINDRES)"; export WINDRES; \
172 OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
173 OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
174 TOPLEVEL_CONFIGURE_ARGUMENTS="$(TOPLEVEL_CONFIGURE_ARGUMENTS)"; export TOPLEVEL_CONFIGURE_ARGUMENTS; \
175 GMPLIBS="$(HOST_GMPLIBS)"; export GMPLIBS; \
176 GMPINC="$(HOST_GMPINC)"; export GMPINC;
178 # Similar, for later GCC stages.
179 STAGE_HOST_EXPORTS = \
181 CC="$(STAGE_CC_WRAPPER) $$r/prev-gcc/xgcc$(exeext) -B$$r/prev-gcc/ -B$(build_tooldir)/bin/"; export CC; \
182 CC_FOR_BUILD="$(STAGE_CC_WRAPPER) $$r/prev-gcc/xgcc$(exeext) -B$$r/prev-gcc/ -B$(build_tooldir)/bin/"; export CC_FOR_BUILD;
184 # This is set by the configure script to the list of directories which
185 # should be built using the target tools.
186 TARGET_CONFIGDIRS = @target_configdirs@
187 # Target libraries are put under this directory:
188 TARGET_SUBDIR = @target_subdir@
189 # This is set by the configure script to the arguments to use when configuring
190 # directories built for the target.
191 TARGET_CONFIGARGS = @target_configargs@
192 # This is the list of variables to export in the environment when
193 # configuring subdirectories for the host system.
194 BASE_TARGET_EXPORTS = \
196 AR="$(AR_FOR_TARGET)"; export AR; \
197 AS="$(AS_FOR_TARGET)"; export AS; \
198 CC="$(CC_FOR_TARGET)"; export CC; \
199 CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
200 CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
201 CPPFLAGS="$(CFLAGS_FOR_TARGET)"; export CPPFLAGS; \
202 CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
203 GCJ="$(GCJ_FOR_TARGET)"; export GCJ; \
204 GFORTRAN="$(GFORTRAN_FOR_TARGET)"; export GFORTRAN; \
205 DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
206 LD="$(LD_FOR_TARGET)"; export LD; \
207 LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
208 NM="$(NM_FOR_TARGET)"; export NM; \
209 RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
210 WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES;
212 RAW_CXX_TARGET_EXPORTS = \
213 $(BASE_TARGET_EXPORTS) \
214 CXX_FOR_TARGET="$(RAW_CXX_FOR_TARGET)"; export CXX_FOR_TARGET; \
215 CXX="$(RAW_CXX_FOR_TARGET)"; export CXX;
217 NORMAL_TARGET_EXPORTS = \
218 $(BASE_TARGET_EXPORTS) \
219 CXX="$(CXX_FOR_TARGET)"; export CXX;
222 HOST_GMPLIBS = @gmplibs@
223 HOST_GMPINC = @gmpinc@
225 # ----------------------------------------------
226 # Programs producing files for the BUILD machine
227 # ----------------------------------------------
229 SHELL = @config_shell@
231 # pwd command to use. Allow user to override default by setting PWDCMD in
232 # the environment to account for automounters. The make variable must not
233 # be called PWDCMD, otherwise the value set here is passed to make
234 # subprocesses and overrides the setting from the user's environment.
235 # Don't use PWD since it is a common shell environment variable and we
236 # don't want to corrupt it.
237 PWD_COMMAND = $${PWDCMD-pwd}
239 # compilers to use to create programs which must be run in the build
241 CC_FOR_BUILD = @CC_FOR_BUILD@
242 CFLAGS_FOR_BUILD = @CFLAGS_FOR_BUILD@
244 CXX_FOR_BUILD = $(CXX)
246 # Path to the build directory for a Canadian cross, empty otherwise.
247 BUILD_DIR_PREFIX = @BUILD_DIR_PREFIX@
249 # Special variables passed down in EXTRA_GCC_FLAGS. They are defined
250 # here so that they can be overridden by Makefile fragments.
251 BUILD_PREFIX = @BUILD_PREFIX@
252 BUILD_PREFIX_1 = @BUILD_PREFIX_1@
254 CONFIGURED_BISON = @CONFIGURED_BISON@
255 BISON = `if [ -f $$r/$(BUILD_DIR_PREFIX)/bison/bison ] ; then \
256 echo $$r/$(BUILD_DIR_PREFIX)/bison/bison -L $$s/bison/ ; \
258 echo ${CONFIGURED_BISON} ; \
261 CONFIGURED_YACC = @CONFIGURED_YACC@
262 YACC = `if [ -f $$s/$(BUILD_DIR_PREFIX)/bison/bison ] ; then \
263 echo $$r/$(BUILD_DIR_PREFIX)/bison/bison -y -L $$s/bison/ ; \
264 elif [ -f $$s/$(BUILD_DIR_PREFIX)/byacc/byacc ] ; then \
265 echo $$r/$(BUILD_DIR_PREFIX)/byacc/byacc ; \
267 echo ${CONFIGURED_YACC} ; \
270 CONFIGURED_FLEX = @CONFIGURED_FLEX@
271 FLEX = `if [ -f $$r/$(BUILD_DIR_PREFIX)/flex/flex ] ; \
272 then echo $$r/$(BUILD_DIR_PREFIX)/flex/flex ; \
273 else echo ${CONFIGURED_FLEX} ; fi`
275 CONFIGURED_LEX = @CONFIGURED_LEX@
276 LEX = `if [ -f $$r/$(BUILD_DIR_PREFIX)/flex/flex ] ; \
277 then echo $$r/$(BUILD_DIR_PREFIX)/flex/flex ; \
278 else echo ${CONFIGURED_LEX} ; fi`
280 CONFIGURED_M4 = @CONFIGURED_M4@
281 M4 = `if [ -f $$r/$(BUILD_DIR_PREFIX)/m4/m4 ] ; \
282 then echo $$r/$(BUILD_DIR_PREFIX)/m4/m4 ; \
283 else echo ${CONFIGURED_M4} ; fi`
285 # For an installed makeinfo, we require it to be from texinfo 4.2 or
286 # higher, else we use the "missing" dummy. We also pass the subdirectory
287 # makeinfo even if only the Makefile is there, because Texinfo builds its
288 # manual when made, and it requires its own version.
289 CONFIGURED_MAKEINFO = @CONFIGURED_MAKEINFO@
290 MAKEINFO = `if [ -f $$r/$(BUILD_DIR_PREFIX)/texinfo/makeinfo/Makefile ] ; \
291 then echo $$r/$(BUILD_DIR_PREFIX)/texinfo/makeinfo/makeinfo ; \
292 else if (${CONFIGURED_MAKEINFO} --version \
293 | egrep 'texinfo[^0-9]*([1-3][0-9]|4\.[2-9]|[5-9])') >/dev/null 2>&1; \
294 then echo ${CONFIGURED_MAKEINFO}; else echo $$s/missing makeinfo; fi; fi`
296 # This just becomes part of the MAKEINFO definition passed down to
297 # sub-makes. It lets flags be given on the command line while still
298 # using the makeinfo from the object tree.
299 # (Default to avoid splitting info files by setting the threshold high.)
300 MAKEINFOFLAGS = --split-size=5000000
302 EXPECT = `if [ -f $$r/expect/expect ] ; \
303 then echo $$r/expect/expect ; \
304 else echo expect ; fi`
306 RUNTEST = `if [ -f $$s/dejagnu/runtest ] ; \
307 then echo $$s/dejagnu/runtest ; \
308 else echo runtest ; fi`
310 # ---------------------------------------------
311 # Programs producing files for the HOST machine
312 # ---------------------------------------------
314 # This is the list of directories that may be needed in RPATH_ENVVAR
315 # so that programs built for the host machine work.
316 HOST_LIB_PATH = $$r/bfd:$$r/opcodes
325 LIBCFLAGS = $(CFLAGS)
328 CXXFLAGS = @CXXFLAGS@
329 LIBCXXFLAGS = $(CXXFLAGS) -fno-implicit-templates
344 # -----------------------------------------------
345 # Programs producing files for the TARGET machine
346 # -----------------------------------------------
348 # This is the list of directories that may be needed in RPATH_ENVVAR
349 # so that prorgams built for the target machine work.
350 TARGET_LIB_PATH = $$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs:$$r/$(TARGET_SUBDIR)/libmudflap/.libs
352 FLAGS_FOR_TARGET = @FLAGS_FOR_TARGET@
354 AR_FOR_TARGET=@AR_FOR_TARGET@
355 CONFIGURED_AR_FOR_TARGET=@CONFIGURED_AR_FOR_TARGET@
356 USUAL_AR_FOR_TARGET = ` \
357 if [ -f $$r/binutils/ar ] ; then \
358 echo $$r/binutils/ar ; \
360 if [ '$(host)' = '$(target)' ] ; then \
363 echo $(CONFIGURED_AR_FOR_TARGET) ; \
367 AS_FOR_TARGET=@AS_FOR_TARGET@
368 CONFIGURED_AS_FOR_TARGET=@CONFIGURED_AS_FOR_TARGET@
369 USUAL_AS_FOR_TARGET = ` \
370 if [ -f $$r/gas/as-new ] ; then \
371 echo $$r/gas/as-new ; \
372 elif [ -f $$r/gcc/xgcc ]; then \
373 $(CC_FOR_TARGET) -print-prog-name=as ; \
375 if [ '$(host)' = '$(target)' ] ; then \
378 echo $(CONFIGURED_AS_FOR_TARGET) ; \
382 CC_FOR_TARGET = @CC_FOR_TARGET@
383 # During gcc bootstrap, if we use some random cc for stage1 then
384 # CFLAGS will be just -g. We want to ensure that TARGET libraries
385 # (which we know are built with gcc) are built with optimizations so
386 # prepend -O2 when setting CFLAGS_FOR_TARGET.
387 CFLAGS_FOR_TARGET = -O2 $(CFLAGS)
388 # If GCC_FOR_TARGET is not overriden on the command line, then this
389 # variable is passed down to the gcc Makefile, where it is used to
390 # build libgcc2.a. We define it here so that it can itself be
391 # overridden on the command line.
392 GCC_FOR_TARGET=@GCC_FOR_TARGET@
393 USUAL_GCC_FOR_TARGET = $(STAGE_CC_WRAPPER) $$r/gcc/xgcc -B$$r/gcc/ $(FLAGS_FOR_TARGET)
394 LIBCFLAGS_FOR_TARGET = $(CFLAGS_FOR_TARGET)
396 CXX_FOR_TARGET = @CXX_FOR_TARGET@
397 RAW_CXX_FOR_TARGET = @RAW_CXX_FOR_TARGET@
398 CXX_FOR_TARGET_FOR_RECURSIVE_MAKE = @CXX_FOR_TARGET_FOR_RECURSIVE_MAKE@
399 RAW_CXX_FOR_TARGET_FOR_RECURSIVE_MAKE = @RAW_CXX_FOR_TARGET_FOR_RECURSIVE_MAKE@
400 CXXFLAGS_FOR_TARGET = $(CXXFLAGS)
401 LIBCXXFLAGS_FOR_TARGET = $(CXXFLAGS_FOR_TARGET) -fno-implicit-templates
403 DLLTOOL_FOR_TARGET=@DLLTOOL_FOR_TARGET@
404 CONFIGURED_DLLTOOL_FOR_TARGET=@CONFIGURED_DLLTOOL_FOR_TARGET@
405 USUAL_DLLTOOL_FOR_TARGET = ` \
406 if [ -f $$r/binutils/dlltool ] ; then \
407 echo $$r/binutils/dlltool ; \
409 if [ '$(host)' = '$(target)' ] ; then \
412 echo $(CONFIGURED_DLLTOOL_FOR_TARGET) ; \
416 GCJ_FOR_TARGET = @GCJ_FOR_TARGET@
417 GFORTRAN_FOR_TARGET = @GFORTRAN_FOR_TARGET@
419 LD_FOR_TARGET=@LD_FOR_TARGET@
420 CONFIGURED_LD_FOR_TARGET=@CONFIGURED_LD_FOR_TARGET@
421 USUAL_LD_FOR_TARGET = ` \
422 if [ -f $$r/ld/ld-new ] ; then \
423 echo $$r/ld/ld-new ; \
424 elif [ -f $$r/gcc/xgcc ]; then \
425 $(CC_FOR_TARGET) -print-prog-name=ld ; \
427 if [ '$(host)' = '$(target)' ] ; then \
430 echo $(CONFIGURED_LD_FOR_TARGET) ; \
436 NM_FOR_TARGET=@NM_FOR_TARGET@
437 CONFIGURED_NM_FOR_TARGET=@CONFIGURED_NM_FOR_TARGET@
438 USUAL_NM_FOR_TARGET = ` \
439 if [ -f $$r/binutils/nm-new ] ; then \
440 echo $$r/binutils/nm-new ; \
441 elif [ -f $$r/gcc/xgcc ]; then \
442 $(CC_FOR_TARGET) -print-prog-name=nm ; \
444 if [ '$(host)' = '$(target)' ] ; then \
447 echo $(CONFIGURED_NM_FOR_TARGET) ; \
451 RANLIB_FOR_TARGET=@RANLIB_FOR_TARGET@
452 CONFIGURED_RANLIB_FOR_TARGET=@CONFIGURED_RANLIB_FOR_TARGET@
453 USUAL_RANLIB_FOR_TARGET = ` \
454 if [ -f $$r/binutils/ranlib ] ; then \
455 echo $$r/binutils/ranlib ; \
457 if [ '$(host)' = '$(target)' ] ; then \
458 if [ x'$(RANLIB)' != x ]; then \
464 echo $(CONFIGURED_RANLIB_FOR_TARGET) ; \
468 WINDRES_FOR_TARGET=@WINDRES_FOR_TARGET@
469 CONFIGURED_WINDRES_FOR_TARGET=@CONFIGURED_WINDRES_FOR_TARGET@
470 USUAL_WINDRES_FOR_TARGET = ` \
471 if [ -f $$r/binutils/windres ] ; then \
472 echo $$r/binutils/windres ; \
474 if [ '$(host)' = '$(target)' ] ; then \
477 echo $(CONFIGURED_WINDRES_FOR_TARGET) ; \
483 # ------------------------------------
484 # Miscellaneous targets and flag lists
485 # ------------------------------------
488 # Let's leave this as the first rule in the file until toplevel
489 # bootstrap is fleshed out completely.
491 @echo Toplevel bootstrap temporarily out of commission.
492 @echo Please reconfigure without --enable-bootstrap
495 # The first rule in the file had better be this one. Don't put any above it.
496 # This lives here to allow makefile fragments to contain dependencies.
499 #### host and target specific makefile fragments come in here.
500 @target_makefile_frag@
506 # Flags to pass down to all sub-makes.
507 BASE_FLAGS_TO_PASS = [+ FOR flags_to_pass +]\
508 "[+flag+]=$([+flag+])" [+ ENDFOR flags_to_pass +]\
509 "CONFIG_SHELL=$(SHELL)" \
510 "MAKEINFO=$(MAKEINFO) $(MAKEINFOFLAGS)"
512 # For any flags above that may contain shell code that varies from one
513 # target library to another. When doing recursive invocations of the
514 # top-level Makefile, we don't want the outer make to evaluate them,
515 # so we pass these variables down unchanged. They must not contain
516 # single nor double quotes.
518 CXX_FOR_TARGET='$(CXX_FOR_TARGET_FOR_RECURSIVE_MAKE)' \
519 RAW_CXX_FOR_TARGET='$(RAW_CXX_FOR_TARGET_FOR_RECURSIVE_MAKE)' \
521 RECURSE_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(RECURSE_FLAGS)
523 # Flags to pass down to most sub-makes, in which we're building with
524 # the host environment.
530 'DLLTOOL=$(DLLTOOL)' \
536 FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_HOST_FLAGS)
538 # Flags that are concerned with the location of the X11 include files
541 # NOTE: until the top-level is getting the values via autoconf, it only
542 # causes problems to have this top-level Makefile overriding the autoconf-set
543 # values in child directories. Only variables that don't conflict with
544 # autoconf'ed ones should be passed by X11_FLAGS_TO_PASS for now.
546 X11_FLAGS_TO_PASS = \
547 'X11_EXTRA_CFLAGS=$(X11_EXTRA_CFLAGS)' \
548 'X11_EXTRA_LIBS=$(X11_EXTRA_LIBS)'
550 # Flags to pass down to makes which are built with the target environment.
551 # The double $ decreases the length of the command line; the variables
552 # are set in BASE_FLAGS_TO_PASS, and the sub-make will expand them.
553 EXTRA_TARGET_FLAGS = \
554 'AR=$$(AR_FOR_TARGET)' \
555 'AS=$$(AS_FOR_TARGET)' \
556 'CC=$$(CC_FOR_TARGET)' \
557 'CFLAGS=$$(CFLAGS_FOR_TARGET)' \
558 'CXX=$$(CXX_FOR_TARGET)' \
559 'CXXFLAGS=$$(CXXFLAGS_FOR_TARGET)' \
560 'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \
561 'LD=$$(LD_FOR_TARGET)' \
562 'LIBCFLAGS=$$(LIBCFLAGS_FOR_TARGET)' \
563 'LIBCXXFLAGS=$$(LIBCXXFLAGS_FOR_TARGET)' \
564 'NM=$$(NM_FOR_TARGET)' \
565 'RANLIB=$$(RANLIB_FOR_TARGET)' \
566 'WINDRES=$$(WINDRES_FOR_TARGET)'
568 TARGET_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_TARGET_FLAGS)
570 # Flags to pass down to gcc. gcc builds a library, libgcc.a, so it
571 # unfortunately needs the native compiler and the target ar and
573 # If any variables are added here, they must be added to do-*, below.
574 # The BUILD_* variables are a special case, which are used for the gcc
575 # cross-building scheme.
577 'BUILD_PREFIX=$(BUILD_PREFIX)' \
578 'BUILD_PREFIX_1=$(BUILD_PREFIX_1)' \
579 "GCC_FOR_TARGET=$(GCC_FOR_TARGET)" \
580 "CFLAGS_FOR_BUILD=$(CFLAGS_FOR_BUILD)" \
581 "`echo 'LANGUAGES=$(LANGUAGES)' | sed -e s'/[^=][^=]*=$$/XFOO=/'`" \
582 "`echo 'STMP_FIXPROTO=$(STMP_FIXPROTO)' | sed -e s'/[^=][^=]*=$$/XFOO=/'`" \
583 "`echo 'LIMITS_H_TEST=$(LIMITS_H_TEST)' | sed -e s'/[^=][^=]*=$$/XFOO=/'`" \
584 "`echo 'LIBGCC2_CFLAGS=$(LIBGCC2_CFLAGS)' | sed -e s'/[^=][^=]*=$$/XFOO=/'`" \
585 "`echo 'LIBGCC2_DEBUG_CFLAGS=$(LIBGCC2_DEBUG_CFLAGS)' | sed -e s'/[^=][^=]*=$$/XFOO=/'`" \
586 "`echo 'LIBGCC2_INCLUDES=$(LIBGCC2_INCLUDES)' | sed -e s'/[^=][^=]*=$$/XFOO=/'`" \
587 "`echo 'STAGE1_CFLAGS=$(STAGE1_CFLAGS)' | sed -e s'/[^=][^=]*=$$/XFOO=/'`" \
588 "`echo 'BOOT_CFLAGS=$(BOOT_CFLAGS)' | sed -e s'/[^=][^=]*=$$/XFOO=/'`" \
589 "`echo 'BOOT_ADAFLAGS=$(BOOT_ADAFLAGS)' | sed -e s'/[^=][^=]*=$$/XFOO=/'`"
591 GCC_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_HOST_FLAGS) $(EXTRA_GCC_FLAGS)
593 .PHONY: configure-host
595 FOR host_modules +] \
596 maybe-configure-[+module+][+
597 ENDFOR host_modules +]
598 .PHONY: configure-target
600 FOR target_modules +] \
601 maybe-configure-target-[+module+][+
602 ENDFOR target_modules +]
604 # The target built for a native non-bootstrap build.
606 all: unstage all-build all-host all-target stage
610 FOR build_modules +] \
611 maybe-all-build-[+module+][+
612 ENDFOR build_modules +]
615 FOR host_modules +] \
616 maybe-all-[+module+][+
617 ENDFOR host_modules +]
620 FOR target_modules +] \
621 maybe-all-target-[+module+][+
622 ENDFOR target_modules +]
624 # Do a target for all the subdirectories. A ``make do-X'' will do a
625 # ``make X'' in all subdirectories (because, in general, there is a
626 # dependency (below) of X upon do-X, a ``make X'' will also do this,
627 # but it may do additional work as well).
628 [+ FOR recursive_targets +]
629 .PHONY: do-[+make_target+]
630 do-[+make_target+]: unstage [+make_target+]-host [+make_target+]-target stage
632 .PHONY: [+make_target+]-host
633 [+make_target+]-host: [+
634 FOR host_modules +] \
635 maybe-[+make_target+]-[+module+][+
636 ENDFOR host_modules +]
638 .PHONY: [+make_target+]-target
639 [+make_target+]-target: [+
640 FOR target_modules +] \
641 maybe-[+make_target+]-target-[+module+][+
642 ENDFOR target_modules +]
643 [+ ENDFOR recursive_targets +]
645 # Here are the targets which correspond to the do-X targets.
647 .PHONY: info installcheck dvi install-info
648 .PHONY: clean distclean mostlyclean maintainer-clean realclean
649 .PHONY: local-clean local-distclean local-maintainer-clean
651 installcheck: do-installcheck
654 # Make sure makeinfo is built before we do a `make info', if we're
655 # in fact building texinfo.
656 do-info: maybe-all-texinfo
658 install-info: do-install-info dir.info
659 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
660 if [ -f dir.info ] ; then \
661 $(INSTALL_DATA) dir.info $(DESTDIR)$(infodir)/dir.info ; \
665 -rm -f *.a TEMP errs core *.o *~ \#* TAGS *.E *.log
668 -rm -f Makefile config.status config.cache mh-frag mt-frag
669 -rm -f multilib.out multilib.tmp maybedep.tmp serdep.tmp
670 -if [ "$(TARGET_SUBDIR)" != "." ]; then \
671 rm -rf $(TARGET_SUBDIR); \
673 -rm -rf $(BUILD_SUBDIR)
674 -rm -f texinfo/po/Makefile texinfo/po/Makefile.in texinfo/info/Makefile
675 -rm -f texinfo/doc/Makefile texinfo/po/POTFILES
676 -rmdir texinfo/doc texinfo/info texinfo/intl texinfo/lib 2>/dev/null
677 -rmdir texinfo/makeinfo texinfo/po texinfo/util 2>/dev/null
678 -rmdir fastjar gcc libiberty texinfo zlib 2>/dev/null
680 local-maintainer-clean:
681 @echo "This command is intended for maintainers to use;"
682 @echo "it deletes files that may require special tools to rebuild."
684 clean: do-clean local-clean
685 mostlyclean: do-mostlyclean local-clean
686 distclean: do-distclean local-clean local-distclean
687 maintainer-clean: local-maintainer-clean do-maintainer-clean local-clean
688 maintainer-clean: local-distclean
689 realclean: maintainer-clean
691 # Extra dependency for clean-target, owing to the mixed nature of gcc
692 clean-target: clean-target-libgcc
694 test ! -d gcc/libgcc || \
695 (cd gcc/libgcc && find . -type d -print) | \
696 while read d; do rm -f gcc/$$d/libgcc.a || : ; done
701 .PHONY: check do-check
704 # Only include modules actually being configured and built.
706 FOR host_modules +] \
707 maybe-check-[+module+][+
708 ENDFOR host_modules +][+
709 FOR target_modules +] \
710 maybe-check-target-[+module+][+
711 ENDFOR target_modules +] stage
713 # Automated reporting of test results.
715 warning.log: build.log
716 $(srcdir)/contrib/warn_summary build.log > $@
719 if test x'$(BOOT_CFLAGS)' != x''; then \
720 BOOT_CFLAGS='$(BOOT_CFLAGS)'; export BOOT_CFLAGS; \
722 $(srcdir)/contrib/test_summary -t >$@
724 echo If you really want to send e-mail, run ./$@ now
726 mail-report-with-warnings.log: warning.log
727 if test x'$(BOOT_CFLAGS)' != x''; then \
728 BOOT_CFLAGS='$(BOOT_CFLAGS)'; export BOOT_CFLAGS; \
730 $(srcdir)/contrib/test_summary -t -i warning.log >$@
732 echo If you really want to send e-mail, run ./$@ now
734 # Installation targets.
736 .PHONY: install uninstall
737 install: installdirs install-host install-target
739 .PHONY: install-host-nogcc
740 install-host-nogcc: [+
741 FOR host_modules +] \
742 maybe-install-[+module+][+
743 ENDFOR host_modules +]
747 FOR host_modules +] \
748 maybe-install-[+module+][+
749 ENDFOR host_modules +]
751 .PHONY: install-target
753 FOR target_modules +] \
754 maybe-install-target-[+module+][+
755 ENDFOR target_modules +]
758 @echo "the uninstall target is not supported in this tree"
761 install.all: install-no-fixedincludes
762 @if [ -f ./gcc/Makefile ] ; then \
763 r=`${PWD_COMMAND}` ; export r ; \
767 $(MAKE) $(FLAGS_TO_PASS) install-headers) ; \
772 # install-no-fixedincludes is used because Cygnus can not distribute
773 # the fixed header files.
774 .PHONY: install-no-fixedincludes
775 install-no-fixedincludes: installdirs install-host-nogcc \
776 install-target gcc-no-fixedincludes
778 ### other supporting targets
781 $(DESTDIR)$(prefix) \
782 $(DESTDIR)$(exec_prefix)
784 installdirs: mkinstalldirs
785 $(SHELL) $(srcdir)/mkinstalldirs $(MAKEDIRS)
787 dir.info: do-install-info
788 if [ -f $(srcdir)/texinfo/gen-info-dir ] ; then \
789 $(srcdir)/texinfo/gen-info-dir $(DESTDIR)$(infodir) $(srcdir)/texinfo/dir.info-template > dir.info.new ; \
790 mv -f dir.info.new dir.info ; \
795 @echo "Building a full distribution of this tree isn't done"
796 @echo "via 'make dist'. Check out the etc/ subdirectory"
800 # Right now this just builds TAGS in each subdirectory. emacs19 has the
801 # ability to use several tags files at once, so there is probably no need
802 # to combine them into one big TAGS file (like CVS 1.3 does). We could
803 # (if we felt like it) have this Makefile write a piece of elisp which
804 # the user could load to tell emacs19 where all the TAGS files we just
808 # --------------------------------------
809 # Modules which run on the build machine
810 # --------------------------------------
811 [+ FOR build_modules +]
812 .PHONY: configure-build-[+module+] maybe-configure-build-[+module+]
813 maybe-configure-build-[+module+]:
815 maybe-configure-build-[+module+]: configure-build-[+module+]
816 configure-build-[+module+]:
817 @test ! -f $(BUILD_SUBDIR)/[+module+]/Makefile || exit 0; \
818 $(SHELL) $(srcdir)/mkinstalldirs $(BUILD_SUBDIR)/[+module+] ; \
819 r=`${PWD_COMMAND}`; export r; \
820 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
822 echo Configuring in $(BUILD_SUBDIR)/[+module+]; \
823 cd "$(BUILD_SUBDIR)/[+module+]" || exit 1; \
825 /* | [A-Za-z]:[\\/]*) \
826 topdir=$(srcdir) ;; \
828 case "$(BUILD_SUBDIR)" in \
829 .) topdir="../$(srcdir)" ;; \
830 *) topdir="../../$(srcdir)" ;; \
833 if [ "$(srcdir)" = "." ] ; then \
834 if [ "$(BUILD_SUBDIR)" != "." ] ; then \
835 if $(SHELL) $$s/symlink-tree $${topdir}/[+module+] "no-such-file" ; then \
836 if [ -f Makefile ]; then \
837 if $(MAKE) distclean; then \
851 srcdiroption="--srcdir=."; \
854 srcdiroption="--srcdir=$${topdir}/[+module+]"; \
855 libsrcdir="$$s/[+module+]"; \
857 rm -f no-such-file || : ; \
858 CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
859 $(BUILD_CONFIGARGS) $${srcdiroption} \
860 --with-build-subdir="$(BUILD_SUBDIR)" [+extra_configure_flags+] \
862 @endif build-[+module+]
864 .PHONY: all-build-[+module+] maybe-all-build-[+module+]
865 maybe-all-build-[+module+]:
867 maybe-all-build-[+module+]: all-build-[+module+]
868 all-build-[+module+]: configure-build-[+module+]
869 @r=`${PWD_COMMAND}`; export r; \
870 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
872 (cd $(BUILD_SUBDIR)/[+module+] && $(MAKE) [+extra_make_flags+] all)
873 @endif build-[+module+]
874 [+ ENDFOR build_modules +]
876 # --------------------------------------
877 # Modules which run on the host machine
878 # --------------------------------------
879 [+ FOR host_modules +]
880 .PHONY: configure-[+module+] maybe-configure-[+module+]
881 maybe-configure-[+module+]:
883 maybe-configure-[+module+]: configure-[+module+]
884 configure-[+module+]:
885 @test ! -f [+module+]/Makefile || exit 0; \
886 [ -d [+module+] ] || mkdir [+module+]; \
887 r=`${PWD_COMMAND}`; export r; \
888 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
890 echo Configuring in [+module+]; \
891 cd [+module+] || exit 1; \
894 srcdiroption="--srcdir=."; \
896 /* | [A-Za-z]:[\\/]*) \
897 srcdiroption="--srcdir=$(srcdir)/[+module+]"; \
898 libsrcdir="$$s/[+module+]";; \
900 srcdiroption="--srcdir=../$(srcdir)/[+module+]"; \
901 libsrcdir="$$s/[+module+]";; \
903 $(SHELL) $${libsrcdir}/configure \
904 $(HOST_CONFIGARGS) $${srcdiroption} [+extra_configure_flags+] \
908 .PHONY: all-[+module+] maybe-all-[+module+]
909 maybe-all-[+module+]:
911 maybe-all-[+module+]: all-[+module+]
912 all-[+module+]: configure-[+module+]
913 @r=`${PWD_COMMAND}`; export r; \
914 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
917 (cd [+module+] && $(MAKE) $(FLAGS_TO_PASS)[+
919 +] $(X11_FLAGS_TO_PASS)[+
920 ENDIF with_x +] [+extra_make_flags+] [+
921 IF (== (get "module") "gcc") +] \
922 `if [ -f gcc/stage_last ]; then echo quickstrap ; else echo all; fi` [+
923 ELSE +]all[+ ENDIF +])
926 .PHONY: check-[+module+] maybe-check-[+module+]
927 maybe-check-[+module+]:
929 maybe-check-[+module+]: check-[+module+]
932 [+ ELIF no_check_cross +]
933 # This module is only tested in a native toolchain.
935 @if [ '$(host)' = '$(target)' ] ; then \
936 r=`${PWD_COMMAND}`; export r; \
937 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
940 (cd [+module+] && $(MAKE) $(FLAGS_TO_PASS)[+
942 +] $(X11_FLAGS_TO_PASS)[+
943 ENDIF with_x +] [+extra_make_flags+] check); \
947 @r=`${PWD_COMMAND}`; export r; \
948 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
951 (cd [+module+] && $(MAKE) $(FLAGS_TO_PASS)[+
953 +] $(X11_FLAGS_TO_PASS)[+
954 ENDIF with_x +] [+extra_make_flags+] check)
958 .PHONY: install-[+module+] maybe-install-[+module+]
959 maybe-install-[+module+]:
961 maybe-install-[+module+]: install-[+module+]
965 install-[+module+]: installdirs
966 @r=`${PWD_COMMAND}`; export r; \
967 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
970 (cd [+module+] && $(MAKE) $(FLAGS_TO_PASS)[+
972 +] $(X11_FLAGS_TO_PASS)[+
973 ENDIF with_x +] [+extra_make_flags+] install)
974 [+ ENDIF no_install +]
977 # Other targets (info, dvi, etc.)
978 [+ FOR recursive_targets +]
979 .PHONY: maybe-[+make_target+]-[+module+] [+make_target+]-[+module+]
980 maybe-[+make_target+]-[+module+]:
982 maybe-[+make_target+]-[+module+]: [+make_target+]-[+module+]
983 [+ IF (match-value? = "missing" (get "make_target") ) +]
984 # [+module+] doesn't support [+make_target+].
985 [+make_target+]-[+module+]:
987 [+make_target+]-[+module+]: [+
989 [+depend+]-[+module+] [+
991 @[ -f ./[+module+]/Makefile ] || exit 0; \
992 r=`${PWD_COMMAND}`; export r; \
993 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
996 for flag in $(EXTRA_HOST_FLAGS) [+extra_make_flags+]; do \
997 eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
999 echo "Doing [+make_target+] in [+module+]" ; \
1001 $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
1002 "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
1003 "RANLIB=$${RANLIB}" \
1004 "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
1009 [+ ENDFOR recursive_targets +]
1010 [+ ENDFOR host_modules +]
1012 # ---------------------------------------
1013 # Modules which run on the target machine
1014 # ---------------------------------------
1015 [+ FOR target_modules +]
1016 .PHONY: configure-target-[+module+] maybe-configure-target-[+module+]
1017 maybe-configure-target-[+module+]:
1018 @if target-[+module+]
1019 maybe-configure-target-[+module+]: configure-target-[+module+]
1021 # There's only one multilib.out. Cleverer subdirs shouldn't need it copied.
1022 $(TARGET_SUBDIR)/[+module+]/multilib.out: multilib.out
1023 $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/[+module+] ; \
1024 rm -f $(TARGET_SUBDIR)/[+module+]/Makefile || : ; \
1025 cp multilib.out $(TARGET_SUBDIR)/[+module+]/multilib.out
1027 configure-target-[+module+]: $(TARGET_SUBDIR)/[+module+]/multilib.out
1028 @test ! -f $(TARGET_SUBDIR)/[+module+]/Makefile || exit 0; \
1029 $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/[+module+] ; \
1030 r=`${PWD_COMMAND}`; export r; \
1031 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1034 $(RAW_CXX_TARGET_EXPORTS) \[+
1036 $(NORMAL_TARGET_EXPORTS) \[+
1038 echo Configuring in $(TARGET_SUBDIR)/[+module+]; \
1039 cd "$(TARGET_SUBDIR)/[+module+]" || exit 1; \
1041 /* | [A-Za-z]:[\\/]*) \
1042 topdir=$(srcdir) ;; \
1044 case "$(TARGET_SUBDIR)" in \
1045 .) topdir="../$(srcdir)" ;; \
1046 *) topdir="../../$(srcdir)" ;; \
1048 esac; \[+ IF stage +]
1049 if [ "$(srcdir)" = "." ] ; then \
1050 if [ "$(TARGET_SUBDIR)" != "." ] ; then \
1051 if $(SHELL) $$s/symlink-tree $${topdir}/[+module+] "no-such-file" ; then \
1052 if [ -f Makefile ]; then \
1053 if $(MAKE) distclean; then \
1067 srcdiroption="--srcdir=."; \
1069 else \[+ ENDIF stage +]
1070 srcdiroption="--srcdir=$${topdir}/[+module+]"; \
1071 libsrcdir="$$s/[+module+]"; \[+ IF stage +]
1072 fi; \[+ ENDIF stage +]
1073 rm -f no-such-file || : ; \
1074 CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
1075 $(TARGET_CONFIGARGS) $${srcdiroption} \
1076 --with-target-subdir="$(TARGET_SUBDIR)" [+extra_configure_flags+] \
1078 @endif target-[+module+]
1080 .PHONY: all-target-[+module+] maybe-all-target-[+module+]
1081 maybe-all-target-[+module+]:
1082 @if target-[+module+]
1083 maybe-all-target-[+module+]: all-target-[+module+]
1084 all-target-[+module+]: configure-target-[+module+]
1085 @r=`${PWD_COMMAND}`; export r; \
1086 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1089 $(RAW_CXX_TARGET_EXPORTS) \[+
1091 $(NORMAL_TARGET_EXPORTS) \[+
1093 (cd $(TARGET_SUBDIR)/[+module+] && \
1094 $(MAKE) $(TARGET_FLAGS_TO_PASS) [+
1096 +] 'CXX=$$(RAW_CXX_FOR_TARGET)' 'CXX_FOR_TARGET=$$(RAW_CXX_FOR_TARGET)' [+
1098 +] [+extra_make_flags+] all)
1099 @endif target-[+module+]
1101 .PHONY: check-target-[+module+] maybe-check-target-[+module+]
1102 maybe-check-target-[+module+]:
1103 @if target-[+module+]
1104 maybe-check-target-[+module+]: check-target-[+module+]
1106 # Dummy target for uncheckable module.
1107 check-target-[+module+]:
1109 check-target-[+module+]:
1110 @r=`${PWD_COMMAND}`; export r; \
1111 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1114 $(RAW_CXX_TARGET_EXPORTS) \[+
1116 $(NORMAL_TARGET_EXPORTS) \[+
1118 (cd $(TARGET_SUBDIR)/[+module+] && \
1119 $(MAKE) $(TARGET_FLAGS_TO_PASS) [+
1121 +] 'CXX=$$(RAW_CXX_FOR_TARGET)' 'CXX_FOR_TARGET=$$(RAW_CXX_FOR_TARGET)' [+
1123 +] [+extra_make_flags+] check)
1124 [+ ENDIF no_check +]
1125 @endif target-[+module+]
1127 .PHONY: install-target-[+module+] maybe-install-target-[+module+]
1128 maybe-install-target-[+module+]:
1129 @if target-[+module+]
1130 maybe-install-target-[+module+]: install-target-[+module+]
1132 # Dummy target for uninstallable.
1133 install-target-[+module+]:
1135 install-target-[+module+]: installdirs
1136 @r=`${PWD_COMMAND}`; export r; \
1137 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1140 $(RAW_CXX_TARGET_EXPORTS) \[+
1142 $(NORMAL_TARGET_EXPORTS) \[+
1144 (cd $(TARGET_SUBDIR)/[+module+] && \
1145 $(MAKE) $(TARGET_FLAGS_TO_PASS) [+extra_make_flags+] install)
1146 [+ ENDIF no_install +]
1147 @endif target-[+module+]
1149 # Other targets (info, dvi, etc.)
1150 [+ FOR recursive_targets +]
1151 .PHONY: maybe-[+make_target+]-target-[+module+] [+make_target+]-target-[+module+]
1152 maybe-[+make_target+]-target-[+module+]:
1153 @if target-[+module+]
1154 maybe-[+make_target+]-target-[+module+]: [+make_target+]-target-[+module+]
1155 [+ IF (match-value? = "missing" (get "make_target") ) +]
1156 # [+module+] doesn't support [+make_target+].
1157 [+make_target+]-target-[+module+]:
1159 [+make_target+]-target-[+module+]: [+
1161 [+depend+]-target-[+module+] [+
1163 @[ -f $(TARGET_SUBDIR)/[+module+]/Makefile ] || exit 0 ; \
1164 r=`${PWD_COMMAND}`; export r; \
1165 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1168 $(RAW_CXX_TARGET_EXPORTS) \[+
1170 $(NORMAL_TARGET_EXPORTS) \[+
1172 echo "Doing [+make_target+] in $(TARGET_SUBDIR)/[+module+]" ; \
1173 for flag in $(EXTRA_TARGET_FLAGS); do \
1174 eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
1176 (cd $(TARGET_SUBDIR)/[+module+] && \
1177 $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
1178 "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
1179 "RANLIB=$${RANLIB}" \
1180 "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
1181 [+extra_make_flags+] [+make_target+]) \
1184 @endif target-[+module+]
1185 [+ ENDFOR recursive_targets +]
1186 [+ ENDFOR target_modules +]
1192 @if gcc-no-bootstrap
1193 # GCC has some more recursive targets, which trigger the old
1194 # (but still current, until the toplevel bootstrap project
1195 # is finished) compiler bootstrapping rules.
1197 GCC_STRAP_TARGETS = bootstrap bootstrap-lean bootstrap2 bootstrap2-lean bootstrap3 bootstrap3-lean bootstrap4 bootstrap4-lean bubblestrap quickstrap cleanstrap restrap
1198 .PHONY: $(GCC_STRAP_TARGETS)
1199 $(GCC_STRAP_TARGETS): all-bootstrap configure-gcc
1200 @r=`${PWD_COMMAND}`; export r; \
1201 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1204 echo "Bootstrapping the compiler"; \
1205 cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) $@
1206 @r=`${PWD_COMMAND}`; export r; \
1207 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1209 *bootstrap4-lean ) \
1210 msg="Comparing stage3 and stage4 of the compiler"; \
1211 compare=compare3-lean ;; \
1213 msg="Comparing stage3 and stage4 of the compiler"; \
1214 compare=compare3 ;; \
1216 msg="Comparing stage2 and stage3 of the compiler"; \
1217 compare=compare-lean ;; \
1219 msg="Comparing stage2 and stage3 of the compiler"; \
1220 compare=compare ;; \
1225 cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) $$compare
1226 @r=`${PWD_COMMAND}`; export r; \
1227 s=`cd $(srcdir); ${PWD_COMMAND}` ; export s; \
1229 echo "Building runtime libraries"; \
1230 $(MAKE) $(RECURSE_FLAGS_TO_PASS) all
1232 profiledbootstrap: all-bootstrap configure-gcc
1233 @r=`${PWD_COMMAND}`; export r; \
1234 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1237 echo "Bootstrapping training compiler"; \
1238 cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) stageprofile_build
1239 @r=`${PWD_COMMAND}`; export r; \
1240 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1243 echo "Building feedback based compiler"; \
1244 cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) stagefeedback_build
1245 @r=`${PWD_COMMAND}`; export r; \
1246 s=`cd $(srcdir); ${PWD_COMMAND}` ; export s; \
1248 echo "Building runtime libraries"; \
1249 $(MAKE) $(RECURSE_FLAGS_TO_PASS) all
1252 cross: all-texinfo all-bison all-byacc all-binutils all-gas all-ld
1253 @r=`${PWD_COMMAND}`; export r; \
1254 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1257 echo "Building the C and C++ compiler"; \
1258 cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) LANGUAGES="c c++"
1259 @r=`${PWD_COMMAND}`; export r; \
1260 s=`cd $(srcdir); ${PWD_COMMAND}` ; export s; \
1262 echo "Building runtime libraries"; \
1263 $(MAKE) $(RECURSE_FLAGS_TO_PASS) LANGUAGES="c c++" all
1264 @endif gcc-no-bootstrap
1267 .PHONY: check-gcc-c++
1269 @if [ -f ./gcc/Makefile ] ; then \
1270 r=`${PWD_COMMAND}`; export r; \
1271 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1274 (cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) check-c++); \
1280 check-c++: check-target-libstdc++-v3 check-gcc-c++
1282 # Install the gcc headers files, but not the fixed include files,
1283 # which Cygnus is not allowed to distribute. This rule is very
1284 # dependent on the workings of the gcc Makefile.in.
1285 .PHONY: gcc-no-fixedincludes
1286 gcc-no-fixedincludes:
1287 @if [ -f ./gcc/Makefile ]; then \
1288 rm -rf gcc/tmp-include; \
1289 mv gcc/include gcc/tmp-include 2>/dev/null; \
1290 mkdir gcc/include; \
1291 cp $(srcdir)/gcc/gsyslimits.h gcc/include/syslimits.h; \
1292 touch gcc/stmp-fixinc gcc/include/fixed; \
1293 rm -f gcc/stmp-headers gcc/stmp-int-hdrs; \
1294 r=`${PWD_COMMAND}`; export r; \
1295 s=`cd $(srcdir); ${PWD_COMMAND}` ; export s; \
1299 $(MAKE) $(GCC_FLAGS_TO_PASS) install); \
1300 rm -rf gcc/include; \
1301 mv gcc/tmp-include gcc/include 2>/dev/null; \
1305 # ---------------------
1306 # GCC bootstrap support
1307 # ---------------------
1309 # We track the current stage (the one in 'gcc') in the stage_current file.
1310 # stage_last instead tracks the stage that was built last. These targets
1311 # are dummy when toplevel bootstrap is not active.
1316 @[ -f stage_current ] || $(MAKE) `cat stage_last`-start
1317 @endif gcc-bootstrap
1322 @$(MAKE) `cat stage_current`-end
1323 @endif gcc-bootstrap
1326 # We name the build directories for the various stages "stage1-gcc",
1327 # "stage2-gcc","stage3-gcc", etc.
1329 # Since the 'compare' process will fail (on debugging information) if any
1330 # directory names are different, we need to link the gcc directory for
1331 # the previous stage to a constant name ('gcc-prev'), and to make the name of
1332 # the build directories constant as well. For the latter, we use naked names
1333 # like 'gcc', because the scripts in that directory assume it. We use
1334 # mv on platforms where symlinks to directories do not work or are not
1337 # At the end of the bootstrap, a symlink to 'stage3-gcc' named 'gcc' must
1338 # be kept, so that libraries can find it. Ick!
1340 # It would be best to preinstall gcc into a staging area (and in the
1341 # future, gather there all prebootstrap packages). This would allow
1342 # assemblers and linkers can be bootstrapped as well as the compiler
1343 # (both in a combined tree, or separately). This however requires some
1344 # change to the gcc driver, again in order to avoid comparison failures.
1346 # Bugs: This is almost certainly not parallel-make safe.
1348 # 'touch' doesn't work right on some platforms.
1349 STAMP = echo timestamp >
1351 # Only build the C compiler for stage1, because that is the only one that
1352 # we can guarantee will build with the native compiler, and also it is the
1353 # only thing useful for building stage2. STAGE1_CFLAGS (via CFLAGS),
1354 # MAKEINFO and MAKEINFOFLAGS are explicitly passed here to make them
1355 # overrideable (for a bootstrap build stage1 also builds gcc.info).
1357 STAGE1_CFLAGS=@stage1_cflags@
1358 STAGE1_LANGUAGES=@stage1_languages@
1360 # We only want to compare .o files, so set this!
1363 # Real targets act phony if they depend on phony targets; this hack
1364 # prevents gratuitous rebuilding of stage 1.
1366 $(MAKE) $(RECURSE_FLAGS_TO_PASS) all-bootstrap
1367 $(STAMP) prebootstrap
1369 # Flags to pass to stage2 and later makes.
1371 POSTSTAGE1_FLAGS_TO_PASS = \
1372 CC="$${CC}" CC_FOR_BUILD="$${CC_FOR_BUILD}" \
1373 STAGE_PREFIX=$$r/stage[+prev+]-gcc/ \
1374 CFLAGS="$(BOOT_CFLAGS)" \
1378 # * We force-disable intermodule optimizations, even if
1379 # --enable-intermodule was passed, since the installed compiler probably
1380 # can't handle them. Luckily, autoconf always respects
1381 # the last argument when conflicting --enable arguments are passed.
1382 # * Likewise, we force-disable coverage flags, since the installed compiler
1383 # probably has never heard of them.
1384 # * We build only C (and possibly Ada).
1386 [+ FOR bootstrap-stage +]
1387 .PHONY: stage[+id+]-start stage[+id+]-end
1390 [ -f stage_current ] && $(MAKE) `cat stage_current`-end || :
1391 echo stage[+id+] > stage_current ; \
1392 echo stage[+id+] > stage_last ; \
1393 [ -d stage[+id+]-gcc ] || mkdir stage[+id+]-gcc; \
1394 set stage[+id+]-gcc gcc ; @CREATE_LINK_TO_DIR@ [+ IF prev +] ; \
1395 set stage[+prev+]-gcc prev-gcc ; @CREATE_LINK_TO_DIR@ [+ ENDIF prev +]
1398 rm -f stage_current ; \
1399 set gcc stage[+id+]-gcc ; @UNDO_LINK_TO_DIR@ [+ IF prev +] ; \
1400 set prev-gcc stage[+prev+]-gcc ; @UNDO_LINK_TO_DIR@ [+ ENDIF prev +]
1402 # Bubble a bugfix through all the stages up to stage [+id+]. They
1403 # are remade, but not reconfigured. The next stage (if any) will not
1404 # be reconfigured as well.
1405 .PHONY: stage[+id+]-bubble
1406 stage[+id+]-bubble:: [+ IF prev +]stage[+prev+]-bubble[+ ENDIF +]
1407 @if [ -f all-stage[+id+]-gcc ] ; then \
1408 echo Remaking stage [+id+] ; \
1409 rm -f all-stage[+id+]-gcc ; \
1411 $(MAKE) $(RECURSE_FLAGS_TO_PASS) all-stage[+id+]-gcc
1414 stage[+prev+]-bubble::
1415 @if [ -f configure-stage[+id+]-gcc ] ; then \
1416 $(STAMP) configure-stage[+id+]-gcc ; \
1420 configure-stage[+id+]-gcc: [+ IF prev +] all-stage[+prev+]-gcc [+
1421 ELSE +] prebootstrap [+ ENDIF prev +]
1422 $(MAKE) stage[+id+]-start
1423 @if [ -f stage[+id+]-gcc/Makefile ] ; then \
1424 $(STAMP) configure-stage[+id+]-gcc ; \
1429 r=`${PWD_COMMAND}`; export r; \
1430 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; [+ IF prev +] \
1431 $(STAGE_HOST_EXPORTS) [+ ELSE prev +] \
1432 $(HOST_EXPORTS) [+ ENDIF prev +] \
1433 echo Configuring stage [+id+] in gcc ; \
1437 srcdiroption="--srcdir=."; \
1439 /* | [A-Za-z]:[\\/]*) \
1440 srcdiroption="--srcdir=$(srcdir)/gcc"; \
1441 libsrcdir="$$s/gcc";; \
1443 srcdiroption="--srcdir=../$(srcdir)/gcc"; \
1444 libsrcdir="$$s/gcc";; \
1446 $(SHELL) $${libsrcdir}/configure \
1447 $(HOST_CONFIGARGS) $${srcdiroption} \
1448 [+extra_configure_flags+] && \
1449 $(STAMP) ../configure-stage[+id+]-gcc
1451 all-stage[+id+]-gcc: configure-stage[+id+]-gcc
1452 $(MAKE) stage[+id+]-start
1453 @r=`${PWD_COMMAND}`; export r; \
1454 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; [+ IF prev +] \
1455 $(STAGE_HOST_EXPORTS) [+ ELSE prev +] \
1456 $(HOST_EXPORTS) [+ ENDIF prev +] \
1458 $(MAKE) $(GCC_FLAGS_TO_PASS) [+ IF prev +] \
1459 $(POSTSTAGE1_FLAGS_TO_PASS) [+ ENDIF prev +] \
1460 [+extra_make_flags+] && $(STAMP) ../all-stage[+id+]-gcc
1462 [+ IF compare-target +]
1463 [+compare-target+]: all-stage[+id+]-gcc
1464 [ -f stage_current ] && $(MAKE) `cat stage_current`-end || :
1465 @r=`${PWD_COMMAND}`; export r; \
1466 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1467 rm -f .bad_compare ; \
1468 cd stage[+id+]-gcc; \
1469 files=`find . -name "*$(objext)" -print` ; \
1471 for file in $${files} ; do \
1472 f1=$$r/stage[+prev+]-gcc/$$file; f2=$$r/stage[+id+]-gcc/$$file; \
1473 @do_compare@ > /dev/null 2>&1; \
1474 test $$? -eq 1 && echo $$file differs >> .bad_compare || true; \
1476 if [ -f .bad_compare ]; then \
1477 echo "Bootstrap comparison failure!"; \
1483 $(STAMP) [+compare-target+]
1484 [+ ENDIF compare-target +]
1486 [+ IF bootstrap-target +]
1487 .PHONY: [+bootstrap-target+]
1488 [+bootstrap-target+]:
1489 $(MAKE) $(RECURSE_FLAGS_TO_PASS) stage[+id+]-bubble [+
1490 IF compare-target +] [+compare-target+] [+
1491 ENDIF compare-target +] all
1492 [+ ENDIF bootstrap-target +]
1494 .PHONY: restage[+id+] touch-stage[+id+] distclean-stage[+id+]
1496 # Rules to wipe a stage and all the following ones, used for cleanstrap
1497 [+ IF prev +]distclean-stage[+prev+]:: distclean-stage[+id+] [+ ENDIF prev +]
1498 distclean-stage[+id+]::
1499 [ -f stage_current ] && $(MAKE) `cat stage_current`-end || :
1500 rm -rf configure-stage[+id+]-gcc all-stage[+id+]-gcc stage[+id+]-gcc [+
1501 IF compare-target +][+compare-target+] [+ ENDIF compare-target +]
1503 # Rules to renew the timestamp on a stage and all the following ones
1504 [+ IF prev +]touch-stage[+prev+]:: touch-stage[+id+] [+ ENDIF prev +]
1506 @[ -f configure-stage[+id+]-gcc ] && \
1507 echo '$(STAMP) configure-stage[+id+]-gcc' && \
1508 $(STAMP) configure-stage[+id+]-gcc; \
1509 [ -f all-stage[+id+]-gcc ] && \
1510 echo '$(STAMP) all-stage[+id+]-gcc' && \
1511 $(STAMP) all-stage[+id+]-gcc; \
1514 # After building a stage, touch the following ones
1515 [+ IF prev +]restage[+prev+]:: touch-stage[+id+] [+ ENDIF prev +]
1517 rm -rf all-stage[+id+]-gcc [+
1518 IF compare-target +][+compare-target+] [+ ENDIF compare-target +]
1519 $(MAKE) $(RECURSE_FLAGS_TO_PASS) [+
1520 IF compare-target +][+compare-target+] [+
1521 ELSE +] all-stage[+id+]-gcc [+ ENDIF compare-target +]
1523 [+ IF cleanstrap-target +]
1524 .PHONY: [+cleanstrap-target+]
1525 [+cleanstrap-target+]: distclean-stage1 [+bootstrap-target+]
1526 [+ ENDIF cleanstrap-target +]
1528 [+ ENDFOR bootstrap-stage +]
1530 stagefeedback-start::
1531 @r=`${PWD_COMMAND}`; export r; \
1532 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1533 cd stageprofile-gcc && \
1534 { find . -type d | sort | sed 's,.*,$(SHELL) '"$$s"'/mkinstalldirs "../gcc/&",' | $(SHELL); } && \
1535 { find . -name '*.*da' | sed 's,.*,$(LN) -f "&" "../gcc/&",' | $(SHELL); }
1537 profiledbootstrap: all-bootstrap configure-gcc
1538 @r=`${PWD_COMMAND}`; export r; \
1539 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1542 echo "Bootstrapping the compiler"; \
1543 $(MAKE) stageprofile-bubble distclean-stagefeedback
1544 @r=`${PWD_COMMAND}`; export r; \
1545 s=`cd $(srcdir); ${PWD_COMMAND}` ; export s; \
1547 echo "Building runtime libraries and training compiler"; \
1548 $(MAKE) $(BASE_FLAGS_TO_PASS) $(RECURSE_FLAGS) all
1549 @r=`${PWD_COMMAND}`; export r; \
1550 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1553 echo "Building feedback based compiler"; \
1554 $(MAKE) stagefeedback-bubble stagefeedback-end
1556 @endif gcc-bootstrap
1558 # --------------------------------------
1559 # Dependencies between different modules
1560 # --------------------------------------
1562 # There are two types of dependencies here: 'hard' dependencies, where one
1563 # module simply won't build without the other; and 'soft' dependencies, where
1564 # if the depended-on module is missing, the depending module will do without
1565 # or find a substitute somewhere (perhaps installed). Soft dependencies
1566 # are specified by depending on a 'maybe-' target. If you're not sure,
1567 # it's safer to use a soft dependency.
1570 all-build-bison: maybe-all-build-texinfo
1571 all-build-flex: maybe-all-build-texinfo
1572 all-build-libiberty: maybe-all-build-texinfo
1573 all-build-m4: maybe-all-build-libiberty maybe-all-build-texinfo
1575 # Host modules specific to gcc.
1576 # GCC needs to identify certain tools.
1577 # GCC also needs the information exported by the intl configure script.
1578 configure-gcc: maybe-configure-intl maybe-configure-binutils maybe-configure-gas maybe-configure-ld maybe-configure-bison maybe-configure-flex
1579 all-gcc: maybe-all-libiberty maybe-all-intl maybe-all-texinfo maybe-all-bison maybe-all-byacc maybe-all-flex maybe-all-binutils maybe-all-gas maybe-all-ld maybe-all-zlib maybe-all-libbanshee maybe-all-libcpp
1580 configure-libcpp: maybe-configure-libiberty maybe-configure-intl
1581 all-libcpp: maybe-all-libiberty maybe-all-intl
1582 # This is a slightly kludgy method of getting dependencies on
1583 # all-build-libiberty correct; it would be better to build it every time.
1584 all-gcc: maybe-all-build-libiberty
1585 all-bootstrap: [+ FOR host_modules +][+ IF bootstrap +]maybe-all-[+module+] [+ ENDIF bootstrap +][+ ENDFOR host_modules +]
1587 # Host modules specific to gdb.
1588 # GDB needs to know that the simulator is being built.
1589 configure-gdb: maybe-configure-itcl maybe-configure-tcl maybe-configure-tk maybe-configure-sim
1591 all-gdb: maybe-all-libiberty maybe-all-opcodes maybe-all-bfd maybe-all-mmalloc maybe-all-readline maybe-all-bison maybe-all-byacc maybe-all-sim $(gdbnlmrequirements) $(GDB_TK)
1592 install-gdb: maybe-install-tcl maybe-install-tk maybe-install-itcl maybe-install-tix maybe-install-libgui
1593 configure-libgui: maybe-configure-tcl maybe-configure-tk
1594 all-libgui: maybe-all-tcl maybe-all-tk maybe-all-itcl
1596 # Host modules specific to binutils.
1597 configure-bfd: configure-libiberty
1598 all-bfd: maybe-all-libiberty maybe-all-intl
1599 all-binutils: maybe-all-libiberty maybe-all-opcodes maybe-all-bfd maybe-all-flex maybe-all-bison maybe-all-byacc maybe-all-intl
1600 # We put install-opcodes before install-binutils because the installed
1601 # binutils might be on PATH, and they might need the shared opcodes
1603 install-binutils: maybe-install-opcodes
1604 # libopcodes depends on libbfd
1605 install-opcodes: maybe-install-bfd
1606 all-gas: maybe-all-libiberty maybe-all-opcodes maybe-all-bfd maybe-all-intl
1607 all-gprof: maybe-all-libiberty maybe-all-bfd maybe-all-opcodes maybe-all-intl
1608 all-ld: maybe-all-libiberty maybe-all-bfd maybe-all-opcodes maybe-all-bison maybe-all-byacc maybe-all-flex maybe-all-intl
1609 all-opcodes: maybe-all-bfd maybe-all-libiberty
1611 # Other host modules in the 'src' repository.
1612 all-dejagnu: maybe-all-tcl maybe-all-expect maybe-all-tk
1613 configure-expect: maybe-configure-tcl maybe-configure-tk
1614 all-expect: maybe-all-tcl maybe-all-tk
1615 configure-itcl: maybe-configure-tcl maybe-configure-tk
1616 all-itcl: maybe-all-tcl maybe-all-tk
1617 # We put install-tcl before install-itcl because itcl wants to run a
1618 # program on installation which uses the Tcl libraries.
1619 install-itcl: maybe-install-tcl
1620 all-sid: maybe-all-libiberty maybe-all-bfd maybe-all-opcodes maybe-all-tcl maybe-all-tk
1621 install-sid: maybe-install-tcl maybe-install-tk
1622 all-sim: maybe-all-libiberty maybe-all-bfd maybe-all-opcodes maybe-all-readline maybe-configure-gdb
1623 configure-tk: maybe-configure-tcl
1624 all-tk: maybe-all-tcl
1625 configure-tix: maybe-configure-tcl maybe-configure-tk
1626 all-tix: maybe-all-tcl maybe-all-tk
1627 all-texinfo: maybe-all-libiberty
1629 # Other host modules. Warning, these are not well tested.
1630 all-autoconf: maybe-all-m4 maybe-all-texinfo
1631 all-automake: maybe-all-m4 maybe-all-texinfo
1632 all-bison: maybe-all-texinfo
1633 all-diff: maybe-all-libiberty
1634 all-fastjar: maybe-all-zlib maybe-all-libiberty
1635 all-fileutils: maybe-all-libiberty
1636 all-flex: maybe-all-libiberty maybe-all-bison maybe-all-byacc
1637 all-gzip: maybe-all-libiberty
1638 all-hello: maybe-all-libiberty
1639 all-m4: maybe-all-libiberty maybe-all-texinfo
1640 all-make: maybe-all-libiberty maybe-all-intl
1641 all-patch: maybe-all-libiberty
1642 all-prms: maybe-all-libiberty
1643 all-recode: maybe-all-libiberty
1644 all-sed: maybe-all-libiberty
1645 all-send-pr: maybe-all-prms
1646 all-tar: maybe-all-libiberty
1647 all-uudecode: maybe-all-libiberty
1649 ALL_GCC = maybe-all-gcc
1650 ALL_GCC_C = $(ALL_GCC) maybe-all-target-newlib maybe-all-target-libgloss
1651 ALL_GCC_CXX = $(ALL_GCC_C) maybe-all-target-libstdc++-v3
1653 # Target modules specific to gcc.
1654 configure-target-boehm-gc: $(ALL_GCC_C) maybe-configure-target-qthreads
1655 configure-target-fastjar: maybe-configure-target-zlib
1656 all-target-fastjar: maybe-all-target-zlib maybe-all-target-libiberty
1657 configure-target-libada: $(ALL_GCC_C)
1658 configure-target-libgfortran: $(ALL_GCC_C)
1659 configure-target-libffi: $(ALL_GCC_C)
1660 configure-target-libjava: $(ALL_GCC_C) maybe-configure-target-zlib maybe-configure-target-boehm-gc maybe-configure-target-qthreads maybe-configure-target-libffi
1661 all-target-libjava: maybe-all-fastjar maybe-all-target-zlib maybe-all-target-boehm-gc maybe-all-target-qthreads maybe-all-target-libffi
1662 configure-target-libobjc: $(ALL_GCC_C)
1663 all-target-libobjc: maybe-all-target-libiberty
1664 configure-target-libstdc++-v3: $(ALL_GCC_C)
1665 all-target-libstdc++-v3: maybe-all-target-libiberty
1666 configure-target-zlib: $(ALL_GCC_C)
1668 # Target modules in the 'src' repository.
1669 configure-target-examples: $(ALL_GCC_C)
1670 configure-target-libgloss: $(ALL_GCC)
1671 all-target-libgloss: maybe-configure-target-newlib
1672 configure-target-libiberty: $(ALL_GCC)
1673 configure-target-libtermcap: $(ALL_GCC_C)
1674 configure-target-newlib: $(ALL_GCC)
1675 configure-target-rda: $(ALL_GCC_C)
1676 configure-target-winsup: $(ALL_GCC_C)
1677 all-target-winsup: maybe-all-target-libiberty maybe-all-target-libtermcap
1679 # Other target modules. Warning, these are not well tested.
1680 configure-target-gperf: $(ALL_GCC_CXX)
1681 all-target-gperf: maybe-all-target-libiberty maybe-all-target-libstdc++-v3
1682 configure-target-qthreads: $(ALL_GCC_C)
1684 # Serialization dependencies. Host configures don't work well in parallel to
1685 # each other, due to contention over config.cache. Target configures and
1686 # build configures are similar.
1687 @serialization_dependencies@
1689 # --------------------------------
1690 # Regenerating top level configury
1691 # --------------------------------
1693 # Multilib.out tells target dirs what multilibs they should build.
1694 # There is really only one copy. We use the 'timestamp' method to
1695 # work around various timestamp bugs on some systems.
1696 # We use move-if-change so that it's only considered updated when it
1697 # actually changes, because it has to depend on a phony target.
1698 multilib.out: maybe-all-gcc
1699 @r=`${PWD_COMMAND}`; export r; \
1700 echo "Checking multilib configuration..."; \
1701 $(CC_FOR_TARGET) --print-multi-lib > multilib.tmp 2> /dev/null ; \
1702 $(SHELL) $(srcdir)/move-if-change multilib.tmp multilib.out ; \
1704 # Rebuilding Makefile.in, using autogen.
1706 $(srcdir)/Makefile.in: @MAINT@ $(srcdir)/Makefile.tpl $(srcdir)/Makefile.def
1707 cd $(srcdir) && $(AUTOGEN) Makefile.def
1709 # Rebuilding Makefile.
1710 Makefile: $(srcdir)/Makefile.in config.status
1711 CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
1713 config.status: configure $(gcc_version_trigger)
1714 CONFIG_SHELL="$(SHELL)" $(SHELL) ./config.status --recheck
1716 # Rebuilding configure.
1718 $(srcdir)/configure: @MAINT@ $(srcdir)/configure.in $(srcdir)/config/acx.m4
1719 cd $(srcdir) && $(AUTOCONF)
1721 # ------------------------------
1722 # Special directives to GNU Make
1723 # ------------------------------
1725 # Don't pass command-line variables to submakes.
1729 # end of Makefile.in