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 gcc driver likes to know the arguments it was configured with.
79 TOPLEVEL_CONFIGURE_ARGUMENTS=@TOPLEVEL_CONFIGURE_ARGUMENTS@
82 build_tooldir = @build_tooldir@
86 # This is the name of the environment variable used for the path to
88 RPATH_ENVVAR = @RPATH_ENVVAR@
90 # This is the list of directories to be built for the build system.
91 BUILD_CONFIGDIRS = libiberty
92 # Build programs are put under this directory.
93 BUILD_SUBDIR = @build_subdir@
94 # This is set by the configure script to the arguments to use when configuring
95 # directories built for the build system.
96 BUILD_CONFIGARGS = @build_configargs@ --with-build-subdir="$(BUILD_SUBDIR)"
98 # This is the list of variables to export in the environment when
99 # configuring any subdirectory. It must also be exported whenever
100 # recursing into a build directory in case that directory's Makefile
103 FLEX="$(FLEX)"; export FLEX; \
104 LEX="$(LEX)"; export LEX; \
105 BISON="$(BISON)"; export BISON; \
106 YACC="$(YACC)"; export YACC; \
107 M4="$(M4)"; export M4; \
108 MAKEINFO="$(MAKEINFO)"; export MAKEINFO;
110 # This is the list of variables to export in the environment when
111 # configuring subdirectories for the build system.
114 AR="$(AR_FOR_BUILD)"; export AR; \
115 AS="$(AS_FOR_BUILD)"; export AS; \
116 CC="$(CC_FOR_BUILD)"; export CC; \
117 CFLAGS="$(CFLAGS_FOR_BUILD)"; export CFLAGS; \
118 CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
119 CXX="$(CXX_FOR_BUILD)"; export CXX; \
120 CXXFLAGS="$(CXXFLAGS_FOR_BUILD)"; export CXXFLAGS; \
121 GCJ="$(GCJ_FOR_BUILD)"; export GCJ; \
122 GFORTRAN="$(GFORTRAN_FOR_BUILD)"; export GFORTRAN; \
123 DLLTOOL="$(DLLTOOL_FOR_BUILD)"; export DLLTOOL; \
124 LD="$(LD_FOR_BUILD)"; export LD; \
125 LDFLAGS="$(LDFLAGS_FOR_BUILD)"; export LDFLAGS; \
126 NM="$(NM_FOR_BUILD)"; export NM; \
127 RANLIB="$(RANLIB_FOR_BUILD)"; export RANLIB; \
128 WINDRES="$(WINDRES_FOR_BUILD)"; export WINDRES;
130 # This is the list of directories to built for the host system.
131 SUBDIRS = @configdirs@
132 # This is set by the configure script to the arguments to use when configuring
133 # directories built for the host system.
134 HOST_CONFIGARGS = @host_configargs@
135 # Host programs are put under this directory, which is . except if building
137 HOST_SUBDIR = @host_subdir@
138 # This is the list of variables to export in the environment when
139 # configuring subdirectories for the host system.
142 CC="$(CC)"; export CC; \
143 CFLAGS="$(CFLAGS)"; export CFLAGS; \
144 CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
145 CXX="$(CXX)"; export CXX; \
146 CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
147 AR="$(AR)"; export AR; \
148 AS="$(AS)"; export AS; \
149 CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
150 DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
151 LD="$(LD)"; export LD; \
152 LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
153 NM="$(NM)"; export NM; \
154 RANLIB="$(RANLIB)"; export RANLIB; \
155 WINDRES="$(WINDRES)"; export WINDRES; \
156 OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
157 OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
158 TOPLEVEL_CONFIGURE_ARGUMENTS="$(TOPLEVEL_CONFIGURE_ARGUMENTS)"; export TOPLEVEL_CONFIGURE_ARGUMENTS; \
159 GMPLIBS="$(HOST_GMPLIBS)"; export GMPLIBS; \
160 GMPINC="$(HOST_GMPINC)"; export GMPINC; \
161 $(RPATH_ENVVAR)=`echo "$(HOST_LIB_PATH)$$$(RPATH_ENVVAR)" | sed 's,::*,:,g;s,^:*,,;s,:*$$,,'`; export $(RPATH_ENVVAR);
163 # Similar, for later GCC stages.
164 STAGE_HOST_EXPORTS = \
165 $(RPATH_ENVVAR)=`echo "$(TARGET_LIB_PATH)$$$(RPATH_ENVVAR)" | sed 's,::*,:,g;s,^:*,,;s,:*$$,,'`; export $(RPATH_ENVVAR); \
167 CC="$(STAGE_CC_WRAPPER) $$r/$(HOST_SUBDIR)/prev-gcc/xgcc$(exeext) \
168 -B$$r/$(HOST_SUBDIR)/prev-gcc/ -B$(build_tooldir)/bin/"; export CC; \
169 CC_FOR_BUILD="$(STAGE_CC_WRAPPER) \
170 $$r/$(HOST_SUBDIR)/prev-gcc/xgcc$(exeext) \
171 -B$$r/$(HOST_SUBDIR)/prev-gcc/ \
172 -B$(build_tooldir)/bin/"; export CC_FOR_BUILD;
174 # This is set by the configure script to the list of directories which
175 # should be built using the target tools.
176 TARGET_CONFIGDIRS = @target_configdirs@
177 # Target libraries are put under this directory:
178 TARGET_SUBDIR = @target_subdir@
179 # This is set by the configure script to the arguments to use when configuring
180 # directories built for the target.
181 TARGET_CONFIGARGS = @target_configargs@ --with-target-subdir="$(TARGET_SUBDIR)"
182 # This is the list of variables to export in the environment when
183 # configuring subdirectories for the host system.
184 BASE_TARGET_EXPORTS = \
186 AR="$(AR_FOR_TARGET)"; export AR; \
187 AS="$(AS_FOR_TARGET)"; export AS; \
188 CC="$(CC_FOR_TARGET)"; export CC; \
189 CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
190 CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
191 CPPFLAGS="$(CPPFLAGS_FOR_TARGET)"; export CPPFLAGS; \
192 CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
193 GCJ="$(GCJ_FOR_TARGET)"; export GCJ; \
194 GFORTRAN="$(GFORTRAN_FOR_TARGET)"; export GFORTRAN; \
195 DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
196 LD="$(LD_FOR_TARGET)"; export LD; \
197 LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
198 NM="$(NM_FOR_TARGET)"; export NM; \
199 RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
200 WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES; \
201 $(RPATH_ENVVAR)=`echo "$(HOST_LIB_PATH)$(TARGET_LIB_PATH)$$$(RPATH_ENVVAR)" | sed 's,::*,:,g;s,^:*,,;s,:*$$,,'`; export $(RPATH_ENVVAR);
203 RAW_CXX_TARGET_EXPORTS = \
204 $(BASE_TARGET_EXPORTS) \
205 CXX_FOR_TARGET="$(RAW_CXX_FOR_TARGET)"; export CXX_FOR_TARGET; \
206 CXX="$(RAW_CXX_FOR_TARGET)"; export CXX;
208 NORMAL_TARGET_EXPORTS = \
209 $(BASE_TARGET_EXPORTS) \
210 CXX="$(CXX_FOR_TARGET)"; export CXX;
213 HOST_GMPLIBS = @gmplibs@
214 HOST_GMPINC = @gmpinc@
216 # ----------------------------------------------
217 # Programs producing files for the BUILD machine
218 # ----------------------------------------------
220 SHELL = @config_shell@
222 # pwd command to use. Allow user to override default by setting PWDCMD in
223 # the environment to account for automounters. The make variable must not
224 # be called PWDCMD, otherwise the value set here is passed to make
225 # subprocesses and overrides the setting from the user's environment.
226 # Don't use PWD since it is a common shell environment variable and we
227 # don't want to corrupt it.
228 PWD_COMMAND = $${PWDCMD-pwd}
230 # compilers to use to create programs which must be run in the build
232 CC_FOR_BUILD = @CC_FOR_BUILD@
233 CFLAGS_FOR_BUILD = @CFLAGS_FOR_BUILD@
235 CXX_FOR_BUILD = $(CXX)
237 # Special variables passed down in EXTRA_GCC_FLAGS. They are defined
238 # here so that they can be overridden by Makefile fragments.
239 BUILD_PREFIX = @BUILD_PREFIX@
240 BUILD_PREFIX_1 = @BUILD_PREFIX_1@
242 # Flags to pass to stage2 and later makes. They are defined
243 # here so that they can be overridden by Makefile fragments.
246 CONFIGURED_BISON = @CONFIGURED_BISON@
247 BISON = `if [ -f $$r/$(BUILD_SUBDIR)/bison/tests/bison ] ; then \
248 echo $$r/$(BUILD_SUBDIR)/bison/tests/bison ; \
250 echo ${CONFIGURED_BISON} ; \
253 CONFIGURED_YACC = @CONFIGURED_YACC@
254 YACC = `if [ -f $$r/$(BUILD_SUBDIR)/bison/tests/bison ] ; then \
255 echo $$r/$(BUILD_SUBDIR)/bison/tests/bison -y ; \
256 elif [ -f $$r/$(BUILD_SUBDIR)/byacc/byacc ] ; then \
257 echo $$r/$(BUILD_SUBDIR)/byacc/byacc ; \
259 echo ${CONFIGURED_YACC} ; \
262 CONFIGURED_FLEX = @CONFIGURED_FLEX@
263 FLEX = `if [ -f $$r/$(BUILD_SUBDIR)/flex/flex ] ; \
264 then echo $$r/$(BUILD_SUBDIR)/flex/flex ; \
265 else echo ${CONFIGURED_FLEX} ; fi`
267 CONFIGURED_LEX = @CONFIGURED_LEX@
268 LEX = `if [ -f $$r/$(BUILD_SUBDIR)/flex/flex ] ; \
269 then echo $$r/$(BUILD_SUBDIR)/flex/flex ; \
270 else echo ${CONFIGURED_LEX} ; fi`
272 CONFIGURED_M4 = @CONFIGURED_M4@
273 M4 = `if [ -f $$r/$(BUILD_SUBDIR)/m4/m4 ] ; \
274 then echo $$r/$(BUILD_SUBDIR)/m4/m4 ; \
275 else echo ${CONFIGURED_M4} ; fi`
277 # For an installed makeinfo, we require it to be from texinfo 4.2 or
278 # higher, else we use the "missing" dummy. We also pass the subdirectory
279 # makeinfo even if only the Makefile is there, because Texinfo builds its
280 # manual when made, and it requires its own version.
281 CONFIGURED_MAKEINFO = @CONFIGURED_MAKEINFO@
282 MAKEINFO = `if [ -f $$r/$(BUILD_SUBDIR)/texinfo/makeinfo/Makefile ] ; \
283 then echo $$r/$(BUILD_SUBDIR)/texinfo/makeinfo/makeinfo ; \
284 else if (${CONFIGURED_MAKEINFO} --version \
285 | egrep 'texinfo[^0-9]*([1-3][0-9]|4\.[2-9]|[5-9])') >/dev/null 2>&1; \
286 then echo ${CONFIGURED_MAKEINFO}; else echo $$s/missing makeinfo; fi; fi`
288 # This just becomes part of the MAKEINFO definition passed down to
289 # sub-makes. It lets flags be given on the command line while still
290 # using the makeinfo from the object tree.
291 # (Default to avoid splitting info files by setting the threshold high.)
292 MAKEINFOFLAGS = --split-size=5000000
294 # FIXME: expect may become a build tool?
295 EXPECT = `if [ -f $$r/$(HOST_SUBDIR)/expect/expect ] ; \
296 then echo $$r/$(HOST_SUBDIR)/expect/expect ; \
297 else echo expect ; fi`
299 RUNTEST = `if [ -f $$s/dejagnu/runtest ] ; \
300 then echo $$s/dejagnu/runtest ; \
301 else echo runtest ; fi`
303 # ---------------------------------------------
304 # Programs producing files for the HOST machine
305 # ---------------------------------------------
314 LIBCFLAGS = $(CFLAGS)
317 CXXFLAGS = @CXXFLAGS@
318 LIBCXXFLAGS = $(CXXFLAGS) -fno-implicit-templates
333 # -----------------------------------------------
334 # Programs producing files for the TARGET machine
335 # -----------------------------------------------
337 FLAGS_FOR_TARGET = @FLAGS_FOR_TARGET@
339 AR_FOR_TARGET=@AR_FOR_TARGET@
340 CONFIGURED_AR_FOR_TARGET=@CONFIGURED_AR_FOR_TARGET@
341 USUAL_AR_FOR_TARGET = ` \
342 if [ -f $$r/$(HOST_SUBDIR)/binutils/ar ] ; then \
343 echo $$r/$(HOST_SUBDIR)/binutils/ar ; \
345 if [ '$(host)' = '$(target)' ] ; then \
348 echo $(CONFIGURED_AR_FOR_TARGET) ; \
352 AS_FOR_TARGET=@AS_FOR_TARGET@
353 CONFIGURED_AS_FOR_TARGET=@CONFIGURED_AS_FOR_TARGET@
354 USUAL_AS_FOR_TARGET = ` \
355 if [ -f $$r/$(HOST_SUBDIR)/gas/as-new ] ; then \
356 echo $$r/$(HOST_SUBDIR)/gas/as-new ; \
357 elif [ -f $$r/$(HOST_SUBDIR)/gcc/xgcc ]; then \
358 $(CC_FOR_TARGET) -print-prog-name=as ; \
360 if [ '$(host)' = '$(target)' ] ; then \
363 echo $(CONFIGURED_AS_FOR_TARGET) ; \
367 CC_FOR_TARGET = @CC_FOR_TARGET@
368 # During gcc bootstrap, if we use some random cc for stage1 then
369 # CFLAGS will be just -g. We want to ensure that TARGET libraries
370 # (which we know are built with gcc) are built with optimizations so
371 # prepend -O2 when setting CFLAGS_FOR_TARGET.
372 CFLAGS_FOR_TARGET = -O2 $(CFLAGS)
373 # If GCC_FOR_TARGET is not overriden on the command line, then this
374 # variable is passed down to the gcc Makefile, where it is used to
375 # build libgcc2.a. We define it here so that it can itself be
376 # overridden on the command line.
377 GCC_FOR_TARGET=@GCC_FOR_TARGET@
378 USUAL_GCC_FOR_TARGET = $(STAGE_CC_WRAPPER) \
379 $$r/$(HOST_SUBDIR)/gcc/xgcc -B$$r/$(HOST_SUBDIR)/gcc/ $(FLAGS_FOR_TARGET)
380 LIBCFLAGS_FOR_TARGET = $(CFLAGS_FOR_TARGET)
382 CXX_FOR_TARGET = @CXX_FOR_TARGET@
383 RAW_CXX_FOR_TARGET = @RAW_CXX_FOR_TARGET@
384 CXX_FOR_TARGET_FOR_RECURSIVE_MAKE = @CXX_FOR_TARGET_FOR_RECURSIVE_MAKE@
385 RAW_CXX_FOR_TARGET_FOR_RECURSIVE_MAKE = @RAW_CXX_FOR_TARGET_FOR_RECURSIVE_MAKE@
386 CXXFLAGS_FOR_TARGET = $(CXXFLAGS)
387 LIBCXXFLAGS_FOR_TARGET = $(CXXFLAGS_FOR_TARGET) -fno-implicit-templates
389 DLLTOOL_FOR_TARGET=@DLLTOOL_FOR_TARGET@
390 CONFIGURED_DLLTOOL_FOR_TARGET=@CONFIGURED_DLLTOOL_FOR_TARGET@
391 USUAL_DLLTOOL_FOR_TARGET = ` \
392 if [ -f $$r/$(HOST_SUBDIR)/binutils/dlltool ] ; then \
393 echo $$r/$(HOST_SUBDIR)/binutils/dlltool ; \
395 if [ '$(host)' = '$(target)' ] ; then \
398 echo $(CONFIGURED_DLLTOOL_FOR_TARGET) ; \
402 GCJ_FOR_TARGET = @GCJ_FOR_TARGET@
403 GFORTRAN_FOR_TARGET = @GFORTRAN_FOR_TARGET@
405 LD_FOR_TARGET=@LD_FOR_TARGET@
406 CONFIGURED_LD_FOR_TARGET=@CONFIGURED_LD_FOR_TARGET@
407 USUAL_LD_FOR_TARGET = ` \
408 if [ -f $$r/$(HOST_SUBDIR)/ld/ld-new ] ; then \
409 echo $$r/$(HOST_SUBDIR)/ld/ld-new ; \
410 elif [ -f $$r/$(HOST_SUBDIR)/gcc/xgcc ]; then \
411 $(CC_FOR_TARGET) -print-prog-name=ld ; \
413 if [ '$(host)' = '$(target)' ] ; then \
416 echo $(CONFIGURED_LD_FOR_TARGET) ; \
422 NM_FOR_TARGET=@NM_FOR_TARGET@
423 CONFIGURED_NM_FOR_TARGET=@CONFIGURED_NM_FOR_TARGET@
424 USUAL_NM_FOR_TARGET = ` \
425 if [ -f $$r/$(HOST_SUBDIR)/binutils/nm-new ] ; then \
426 echo $$r/$(HOST_SUBDIR)/binutils/nm-new ; \
427 elif [ -f $$r/$(HOST_SUBDIR)/gcc/xgcc ]; then \
428 $(CC_FOR_TARGET) -print-prog-name=nm ; \
430 if [ '$(host)' = '$(target)' ] ; then \
433 echo $(CONFIGURED_NM_FOR_TARGET) ; \
437 RANLIB_FOR_TARGET=@RANLIB_FOR_TARGET@
438 CONFIGURED_RANLIB_FOR_TARGET=@CONFIGURED_RANLIB_FOR_TARGET@
439 USUAL_RANLIB_FOR_TARGET = ` \
440 if [ -f $$r/$(HOST_SUBDIR)/binutils/ranlib ] ; then \
441 echo $$r/$(HOST_SUBDIR)/binutils/ranlib ; \
443 if [ '$(host)' = '$(target)' ] ; then \
444 if [ x'$(RANLIB)' != x ]; then \
450 echo $(CONFIGURED_RANLIB_FOR_TARGET) ; \
454 WINDRES_FOR_TARGET=@WINDRES_FOR_TARGET@
455 CONFIGURED_WINDRES_FOR_TARGET=@CONFIGURED_WINDRES_FOR_TARGET@
456 USUAL_WINDRES_FOR_TARGET = ` \
457 if [ -f $$r/$(HOST_SUBDIR)/binutils/windres ] ; then \
458 echo $$r/$(HOST_SUBDIR)/binutils/windres ; \
460 if [ '$(host)' = '$(target)' ] ; then \
463 echo $(CONFIGURED_WINDRES_FOR_TARGET) ; \
469 # ------------------------------------
470 # Miscellaneous targets and flag lists
471 # ------------------------------------
473 # The first rule in the file had better be this one. Don't put any above it.
474 # This lives here to allow makefile fragments to contain dependencies.
477 #### host and target specific makefile fragments come in here.
478 @target_makefile_frag@
484 # This is the list of directories that may be needed in RPATH_ENVVAR
485 # so that prorgams built for the target machine work.
486 TARGET_LIB_PATH = [+ FOR target_modules +][+
487 IF lib_path +]$(TARGET_LIB_PATH_[+module+])[+ ENDIF lib_path +][+
488 ENDFOR target_modules +]$(HOST_LIB_PATH_gcc)
489 [+ FOR target_modules +][+ IF lib_path +]
490 @if target-[+module+]
491 TARGET_LIB_PATH_[+module+] = $$r/$(TARGET_SUBDIR)/[+module+]/[+lib_path+]:
492 @endif target-[+module+]
493 [+ ENDIF lib_path +][+ ENDFOR target_modules +]
496 # This is the list of directories that may be needed in RPATH_ENVVAR
497 # so that programs built for the host machine work.
498 HOST_LIB_PATH = [+ FOR host_modules +][+
499 IF lib_path +]$(HOST_LIB_PATH_[+module+])[+ ENDIF lib_path +][+
500 ENDFOR host_modules +]
502 # Define HOST_LIB_PATH_gcc here, for the sake of TARGET_LIB_PATH, ouch
504 HOST_LIB_PATH_gcc = $$r/$(HOST_SUBDIR)/gcc:$$r/$(HOST_SUBDIR)/prev-gcc:
507 [+ FOR host_modules +][+ IF lib_path +]
509 HOST_LIB_PATH_[+module+] = \
510 $$r/$(HOST_SUBDIR)/[+module+]/[+lib_path+]:[+ IF bootstrap
511 +]$$r/$(HOST_SUBDIR)/prev-[+module+]/[+lib_path+]:[+ ENDIF bootstrap +]
513 [+ ENDIF lib_path +][+ ENDFOR host_modules +]
515 # Flags to pass down to all sub-makes.
516 BASE_FLAGS_TO_PASS = [+ FOR flags_to_pass +]\
517 "[+flag+]=$([+flag+])" [+ ENDFOR flags_to_pass +]\
518 "CONFIG_SHELL=$(SHELL)" \
519 "MAKEINFO=$(MAKEINFO) $(MAKEINFOFLAGS)"
521 # For any flags above that may contain shell code that varies from one
522 # target library to another. When doing recursive invocations of the
523 # top-level Makefile, we don't want the outer make to evaluate them,
524 # so we pass these variables down unchanged. They must not contain
525 # single nor double quotes.
527 CXX_FOR_TARGET='$(CXX_FOR_TARGET_FOR_RECURSIVE_MAKE)' \
528 RAW_CXX_FOR_TARGET='$(RAW_CXX_FOR_TARGET_FOR_RECURSIVE_MAKE)' \
530 RECURSE_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(RECURSE_FLAGS)
532 # Flags to pass down to most sub-makes, in which we're building with
533 # the host environment.
539 'DLLTOOL=$(DLLTOOL)' \
545 FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_HOST_FLAGS)
547 # Flags that are concerned with the location of the X11 include files
550 # NOTE: until the top-level is getting the values via autoconf, it only
551 # causes problems to have this top-level Makefile overriding the autoconf-set
552 # values in child directories. Only variables that don't conflict with
553 # autoconf'ed ones should be passed by X11_FLAGS_TO_PASS for now.
555 X11_FLAGS_TO_PASS = \
556 'X11_EXTRA_CFLAGS=$(X11_EXTRA_CFLAGS)' \
557 'X11_EXTRA_LIBS=$(X11_EXTRA_LIBS)'
559 # Flags to pass down to makes which are built with the target environment.
560 # The double $ decreases the length of the command line; the variables
561 # are set in BASE_FLAGS_TO_PASS, and the sub-make will expand them.
562 EXTRA_TARGET_FLAGS = \
563 'AR=$$(AR_FOR_TARGET)' \
564 'AS=$$(AS_FOR_TARGET)' \
565 'CC=$$(CC_FOR_TARGET)' \
566 'CFLAGS=$$(CFLAGS_FOR_TARGET)' \
567 'CXX=$$(CXX_FOR_TARGET)' \
568 'CXXFLAGS=$$(CXXFLAGS_FOR_TARGET)' \
569 'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \
570 'LD=$$(LD_FOR_TARGET)' \
571 'LIBCFLAGS=$$(LIBCFLAGS_FOR_TARGET)' \
572 'LIBCXXFLAGS=$$(LIBCXXFLAGS_FOR_TARGET)' \
573 'NM=$$(NM_FOR_TARGET)' \
574 'RANLIB=$$(RANLIB_FOR_TARGET)' \
575 'WINDRES=$$(WINDRES_FOR_TARGET)'
577 TARGET_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_TARGET_FLAGS)
579 # Flags to pass down to gcc. gcc builds a library, libgcc.a, so it
580 # unfortunately needs the native compiler and the target ar and
582 # If any variables are added here, they must be added to do-*, below.
583 # The BUILD_* variables are a special case, which are used for the gcc
584 # cross-building scheme.
586 'BUILD_PREFIX=$(BUILD_PREFIX)' \
587 'BUILD_PREFIX_1=$(BUILD_PREFIX_1)' \
588 "GCC_FOR_TARGET=$(GCC_FOR_TARGET)" \
589 "CFLAGS_FOR_BUILD=$(CFLAGS_FOR_BUILD)" \
590 "`echo 'LANGUAGES=$(LANGUAGES)' | sed -e s'/[^=][^=]*=$$/XFOO=/'`" \
591 "`echo 'STMP_FIXPROTO=$(STMP_FIXPROTO)' | sed -e s'/[^=][^=]*=$$/XFOO=/'`" \
592 "`echo 'LIMITS_H_TEST=$(LIMITS_H_TEST)' | sed -e s'/[^=][^=]*=$$/XFOO=/'`" \
593 "`echo 'LIBGCC2_CFLAGS=$(LIBGCC2_CFLAGS)' | sed -e s'/[^=][^=]*=$$/XFOO=/'`" \
594 "`echo 'LIBGCC2_DEBUG_CFLAGS=$(LIBGCC2_DEBUG_CFLAGS)' | sed -e s'/[^=][^=]*=$$/XFOO=/'`" \
595 "`echo 'LIBGCC2_INCLUDES=$(LIBGCC2_INCLUDES)' | sed -e s'/[^=][^=]*=$$/XFOO=/'`" \
596 "`echo 'STAGE1_CFLAGS=$(STAGE1_CFLAGS)' | sed -e s'/[^=][^=]*=$$/XFOO=/'`" \
597 "`echo 'BOOT_CFLAGS=$(BOOT_CFLAGS)' | sed -e s'/[^=][^=]*=$$/XFOO=/'`" \
598 "`echo 'BOOT_ADAFLAGS=$(BOOT_ADAFLAGS)' | sed -e s'/[^=][^=]*=$$/XFOO=/'`"
600 GCC_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_HOST_FLAGS) $(EXTRA_GCC_FLAGS)
602 .PHONY: configure-host
604 FOR host_modules +] \
605 maybe-configure-[+module+][+
606 ENDFOR host_modules +]
607 .PHONY: configure-target
609 FOR target_modules +] \
610 maybe-configure-target-[+module+][+
611 ENDFOR target_modules +]
613 # The target built for a native non-bootstrap build.
615 all: unstage all-host all-target stage
619 FOR build_modules +] \
620 maybe-all-build-[+module+][+
621 ENDFOR build_modules +]
624 FOR host_modules +] \
625 maybe-all-[+module+][+
626 ENDFOR host_modules +]
629 FOR target_modules +] \
630 maybe-all-target-[+module+][+
631 ENDFOR target_modules +]
633 # Do a target for all the subdirectories. A ``make do-X'' will do a
634 # ``make X'' in all subdirectories (because, in general, there is a
635 # dependency (below) of X upon do-X, a ``make X'' will also do this,
636 # but it may do additional work as well).
637 [+ FOR recursive_targets +]
638 .PHONY: do-[+make_target+]
639 do-[+make_target+]: unstage [+make_target+]-host [+make_target+]-target stage
641 .PHONY: [+make_target+]-host
642 [+make_target+]-host: [+
643 FOR host_modules +] \
644 maybe-[+make_target+]-[+module+][+
645 ENDFOR host_modules +]
647 .PHONY: [+make_target+]-target
648 [+make_target+]-target: [+
649 FOR target_modules +] \
650 maybe-[+make_target+]-target-[+module+][+
651 ENDFOR target_modules +]
652 [+ ENDFOR recursive_targets +]
654 # Here are the targets which correspond to the do-X targets.
656 .PHONY: info installcheck dvi html install-info
657 .PHONY: clean distclean mostlyclean maintainer-clean realclean
658 .PHONY: local-clean local-distclean local-maintainer-clean
660 installcheck: do-installcheck
664 # Make sure makeinfo is built before we do a `make info', if we're
665 # in fact building texinfo.
666 do-info: maybe-all-texinfo
668 install-info: do-install-info dir.info
669 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
670 if [ -f dir.info ] ; then \
671 $(INSTALL_DATA) dir.info $(DESTDIR)$(infodir)/dir.info ; \
675 -rm -f *.a TEMP errs core *.o *~ \#* TAGS *.E *.log
678 -rm -f Makefile config.status config.cache mh-frag mt-frag
679 -rm -f multilib.out multilib.tmp maybedep.tmp serdep.tmp
680 -if [ "$(TARGET_SUBDIR)" != "." ]; then \
681 rm -rf $(TARGET_SUBDIR); \
683 -rm -rf $(BUILD_SUBDIR)
684 -if [ "$(HOST_SUBDIR)" != "." ]; then \
685 rm -rf $(HOST_SUBDIR); \
687 -rm -f texinfo/po/Makefile texinfo/po/Makefile.in texinfo/info/Makefile
688 -rm -f texinfo/doc/Makefile texinfo/po/POTFILES
689 -rmdir texinfo/doc texinfo/info texinfo/intl texinfo/lib 2>/dev/null
690 -rmdir texinfo/makeinfo texinfo/po texinfo/util 2>/dev/null
691 -rmdir fastjar gcc libiberty texinfo zlib 2>/dev/null
693 local-maintainer-clean:
694 @echo "This command is intended for maintainers to use;"
695 @echo "it deletes files that may require special tools to rebuild."
697 clean: do-clean local-clean
698 mostlyclean: do-mostlyclean local-clean
699 distclean: do-distclean local-clean local-distclean
700 maintainer-clean: local-maintainer-clean do-maintainer-clean local-clean
701 maintainer-clean: local-distclean
702 realclean: maintainer-clean
704 # Extra dependency for clean-target, owing to the mixed nature of gcc
705 clean-target: clean-target-libgcc
707 test ! -d gcc/libgcc || \
708 (cd gcc/libgcc && find . -type d -print) | \
709 while read d; do rm -f gcc/$$d/libgcc.a || : ; done
715 .PHONY: check do-check
718 # Only include modules actually being configured and built.
720 FOR host_modules +] \
721 maybe-check-[+module+][+
722 ENDFOR host_modules +][+
723 FOR target_modules +] \
724 maybe-check-target-[+module+][+
725 ENDFOR target_modules +] stage
727 # Automated reporting of test results.
729 warning.log: build.log
730 $(srcdir)/contrib/warn_summary build.log > $@
733 if test x'$(BOOT_CFLAGS)' != x''; then \
734 BOOT_CFLAGS='$(BOOT_CFLAGS)'; export BOOT_CFLAGS; \
736 $(srcdir)/contrib/test_summary -t >$@
738 echo If you really want to send e-mail, run ./$@ now
740 mail-report-with-warnings.log: warning.log
741 if test x'$(BOOT_CFLAGS)' != x''; then \
742 BOOT_CFLAGS='$(BOOT_CFLAGS)'; export BOOT_CFLAGS; \
744 $(srcdir)/contrib/test_summary -t -i warning.log >$@
746 echo If you really want to send e-mail, run ./$@ now
748 # Installation targets.
750 .PHONY: install uninstall
751 install: installdirs install-host install-target
753 .PHONY: install-host-nogcc
754 install-host-nogcc: [+
755 FOR host_modules +][+ IF (not (= (get "module") "gcc")) +] \
756 maybe-install-[+module+][+ ENDIF +][+
757 ENDFOR host_modules +]
761 FOR host_modules +] \
762 maybe-install-[+module+][+
763 ENDFOR host_modules +]
765 .PHONY: install-target
767 FOR target_modules +] \
768 maybe-install-target-[+module+][+
769 ENDFOR target_modules +]
772 @echo "the uninstall target is not supported in this tree"
775 install.all: install-no-fixedincludes
776 @if [ -f ./gcc/Makefile ] ; then \
777 r=`${PWD_COMMAND}` ; export r ; \
780 $(MAKE) $(FLAGS_TO_PASS) install-headers) ; \
785 # install-no-fixedincludes is used because Cygnus can not distribute
786 # the fixed header files.
787 .PHONY: install-no-fixedincludes
788 install-no-fixedincludes: installdirs install-host-nogcc \
789 install-target gcc-no-fixedincludes
791 ### other supporting targets
794 $(DESTDIR)$(prefix) \
795 $(DESTDIR)$(exec_prefix)
797 installdirs: mkinstalldirs
798 $(SHELL) $(srcdir)/mkinstalldirs $(MAKEDIRS)
800 dir.info: do-install-info
801 if [ -f $(srcdir)/texinfo/gen-info-dir ] ; then \
802 $(srcdir)/texinfo/gen-info-dir $(DESTDIR)$(infodir) $(srcdir)/texinfo/dir.info-template > dir.info.new ; \
803 mv -f dir.info.new dir.info ; \
808 @echo "Building a full distribution of this tree isn't done"
809 @echo "via 'make dist'. Check out the etc/ subdirectory"
813 # Right now this just builds TAGS in each subdirectory. emacs19 has the
814 # ability to use several tags files at once, so there is probably no need
815 # to combine them into one big TAGS file (like CVS 1.3 does). We could
816 # (if we felt like it) have this Makefile write a piece of elisp which
817 # the user could load to tell emacs19 where all the TAGS files we just
821 # ------------------------------------
822 # Macros for configure and all targets
823 # ------------------------------------
825 [+ DEFINE configure +]
826 .PHONY: configure-[+prefix+][+module+] maybe-configure-[+prefix+][+module+]
827 maybe-configure-[+prefix+][+module+]:
828 @if [+prefix+][+module+]
829 maybe-configure-[+prefix+][+module+]: configure-[+prefix+][+module+]
830 configure-[+prefix+][+module+]: [+deps+]
831 @[+ IF bootstrap +]test -f stage_last && exit 0; \
832 [+ ENDIF bootstrap +]test ! -f [+subdir+]/[+module+]/Makefile || exit 0; \
833 $(SHELL) $(srcdir)/mkinstalldirs [+subdir+]/[+module+] ; \
834 r=`${PWD_COMMAND}`; export r; \
835 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
837 echo Configuring in [+subdir+]/[+module+]; \
838 cd "[+subdir+]/[+module+]" || exit 1; \
840 /* | [A-Za-z]:[\\/]*) topdir=$(srcdir) ;; \
841 *) topdir=`echo [+subdir+]/[+module+]/ | \
842 sed -e 's,\./,,g' -e 's,[^/]*/,../,g' `$(srcdir) ;; \
844 srcdiroption="--srcdir=$${topdir}/[+module+]"; \
845 libsrcdir="$$s/[+module+]"; \
846 [+ IF no-config-site +]rm -f no-such-file || : ; \
847 CONFIG_SITE=no-such-file [+ ENDIF +]$(SHELL) $${libsrcdir}/configure \
848 [+args+] $${srcdiroption} [+extra_configure_flags+] \
850 @endif [+prefix+][+module+]
854 .PHONY: all-[+prefix+][+module+] maybe-all-[+prefix+][+module+]
855 maybe-all-[+prefix+][+module+]:
856 @if [+prefix+][+module+]
857 TARGET-[+prefix+][+module+]=[+
858 IF target +][+target+][+ ELSE +]all[+ ENDIF target +]
859 maybe-all-[+prefix+][+module+]: all-[+prefix+][+module+]
860 all-[+prefix+][+module+]: configure-[+prefix+][+module+]
861 @[+ IF bootstrap +]test -f stage_last && exit 0; \
862 [+ ENDIF bootstrap +]r=`${PWD_COMMAND}`; export r; \
863 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
865 (cd [+subdir+]/[+module+] && \
866 $(MAKE) [+args+] [+extra_make_flags+] $(TARGET-[+prefix+][+module+]))
867 @endif [+prefix+][+module+]
870 # --------------------------------------
871 # Modules which run on the build machine
872 # --------------------------------------
873 [+ FOR build_modules +]
874 [+ configure prefix="build-" subdir="$(BUILD_SUBDIR)" exports="$(BUILD_EXPORTS)"
875 args="$(BUILD_CONFIGARGS)" no-config-site=true +]
877 [+ all prefix="build-" subdir="$(BUILD_SUBDIR)" exports="$(BUILD_EXPORTS)" +]
878 [+ ENDFOR build_module +]
880 # --------------------------------------
881 # Modules which run on the host machine
882 # --------------------------------------
883 [+ FOR host_modules +]
884 [+ configure prefix="" subdir="$(HOST_SUBDIR)" exports="$(HOST_EXPORTS)"
885 args="$(HOST_CONFIGARGS)" +]
887 [+ all prefix="" subdir="$(HOST_SUBDIR)" exports="$(HOST_EXPORTS)"
888 args="$(FLAGS_TO_PASS)" +]
890 .PHONY: check-[+module+] maybe-check-[+module+]
891 maybe-check-[+module+]:
893 maybe-check-[+module+]: check-[+module+]
896 [+ ELIF no_check_cross +]
897 # This module is only tested in a native toolchain.
899 @if [ '$(host)' = '$(target)' ] ; then \
900 r=`${PWD_COMMAND}`; export r; \
901 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
903 (cd $(HOST_SUBDIR)/[+module+] && \
904 $(MAKE) $(FLAGS_TO_PASS) [+extra_make_flags+] check); \
908 @r=`${PWD_COMMAND}`; export r; \
909 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
911 (cd $(HOST_SUBDIR)/[+module+] && \
912 $(MAKE) $(FLAGS_TO_PASS) [+extra_make_flags+] check)
916 .PHONY: install-[+module+] maybe-install-[+module+]
917 maybe-install-[+module+]:
919 maybe-install-[+module+]: install-[+module+]
923 install-[+module+]: installdirs
924 @r=`${PWD_COMMAND}`; export r; \
925 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
927 (cd $(HOST_SUBDIR)/[+module+] && \
928 $(MAKE) $(FLAGS_TO_PASS) [+extra_make_flags+] install)
929 [+ ENDIF no_install +]
932 # Other targets (info, dvi, etc.)
933 [+ FOR recursive_targets +]
934 .PHONY: maybe-[+make_target+]-[+module+] [+make_target+]-[+module+]
935 maybe-[+make_target+]-[+module+]:
937 maybe-[+make_target+]-[+module+]: [+make_target+]-[+module+]
938 [+ IF (match-value? = "missing" (get "make_target") ) +]
939 # [+module+] doesn't support [+make_target+].
940 [+make_target+]-[+module+]:
942 [+make_target+]-[+module+]: [+
944 [+depend+]-[+module+] [+
946 @[ -f ./[+module+]/Makefile ] || exit 0; \
947 r=`${PWD_COMMAND}`; export r; \
948 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
950 for flag in $(EXTRA_HOST_FLAGS) [+extra_make_flags+]; do \
951 eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
953 echo "Doing [+make_target+] in [+module+]" ; \
954 (cd $(HOST_SUBDIR)/[+module+] && \
955 $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
956 "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
957 "RANLIB=$${RANLIB}" \
958 "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
963 [+ ENDFOR recursive_targets +]
964 [+ ENDFOR host_modules +]
966 # ---------------------------------------
967 # Modules which run on the target machine
968 # ---------------------------------------
969 [+ FOR target_modules +]
971 # There's only one multilib.out. Cleverer subdirs shouldn't need it copied.
972 @if target-[+module+]
973 $(TARGET_SUBDIR)/[+module+]/multilib.out: multilib.out
974 $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/[+module+] ; \
975 rm -f $(TARGET_SUBDIR)/[+module+]/Makefile || : ; \
976 cp multilib.out $(TARGET_SUBDIR)/[+module+]/multilib.out
977 @endif target-[+module+]
980 [+ configure prefix="target-" subdir="$(TARGET_SUBDIR)"
981 deps=(string-append "$(TARGET_SUBDIR)/" (get "module") "/multilib.out")
982 exports="$(RAW_CXX_TARGET_EXPORTS)"
983 args="$(TARGET_CONFIGARGS)" no-config-site=true +]
985 [+ all prefix="target-" subdir="$(TARGET_SUBDIR)"
986 exports="$(RAW_CXX_TARGET_EXPORTS)"
987 args="$(TARGET_FLAGS_TO_PASS) 'CXX=$$(RAW_CXX_FOR_TARGET)' 'CXX_FOR_TARGET=$$(RAW_CXX_FOR_TARGET)'" +]
989 [+ configure prefix="target-" subdir="$(TARGET_SUBDIR)"
990 deps=(string-append "$(TARGET_SUBDIR)/" (get "module") "/multilib.out")
991 exports="$(NORMAL_TARGET_EXPORTS)"
992 args="$(TARGET_CONFIGARGS)" no-config-site=true +]
994 [+ all prefix="target-" subdir="$(TARGET_SUBDIR)"
995 exports="$(NORMAL_TARGET_EXPORTS)"
996 args="$(TARGET_FLAGS_TO_PASS)" +]
999 .PHONY: check-target-[+module+] maybe-check-target-[+module+]
1000 maybe-check-target-[+module+]:
1001 @if target-[+module+]
1002 maybe-check-target-[+module+]: check-target-[+module+]
1004 # Dummy target for uncheckable module.
1005 check-target-[+module+]:
1007 check-target-[+module+]:
1008 @r=`${PWD_COMMAND}`; export r; \
1009 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \[+
1011 $(RAW_CXX_TARGET_EXPORTS) \[+
1013 $(NORMAL_TARGET_EXPORTS) \[+
1015 (cd $(TARGET_SUBDIR)/[+module+] && \
1016 $(MAKE) $(TARGET_FLAGS_TO_PASS) [+
1018 +] 'CXX=$$(RAW_CXX_FOR_TARGET)' 'CXX_FOR_TARGET=$$(RAW_CXX_FOR_TARGET)' [+
1020 +] [+extra_make_flags+] check)
1021 [+ ENDIF no_check +]
1022 @endif target-[+module+]
1024 .PHONY: install-target-[+module+] maybe-install-target-[+module+]
1025 maybe-install-target-[+module+]:
1026 @if target-[+module+]
1027 maybe-install-target-[+module+]: install-target-[+module+]
1029 # Dummy target for uninstallable.
1030 install-target-[+module+]:
1032 install-target-[+module+]: installdirs
1033 @r=`${PWD_COMMAND}`; export r; \
1034 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \[+
1036 $(RAW_CXX_TARGET_EXPORTS) \[+
1038 $(NORMAL_TARGET_EXPORTS) \[+
1040 (cd $(TARGET_SUBDIR)/[+module+] && \
1041 $(MAKE) $(TARGET_FLAGS_TO_PASS) [+extra_make_flags+] install)
1042 [+ ENDIF no_install +]
1043 @endif target-[+module+]
1045 # Other targets (info, dvi, etc.)
1046 [+ FOR recursive_targets +]
1047 .PHONY: maybe-[+make_target+]-target-[+module+] [+make_target+]-target-[+module+]
1048 maybe-[+make_target+]-target-[+module+]:
1049 @if target-[+module+]
1050 maybe-[+make_target+]-target-[+module+]: [+make_target+]-target-[+module+]
1051 [+ IF (match-value? = "missing" (get "make_target") ) +]
1052 # [+module+] doesn't support [+make_target+].
1053 [+make_target+]-target-[+module+]:
1055 [+make_target+]-target-[+module+]: [+
1057 [+depend+]-target-[+module+] [+
1059 @[ -f $(TARGET_SUBDIR)/[+module+]/Makefile ] || exit 0 ; \
1060 r=`${PWD_COMMAND}`; export r; \
1061 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \[+
1063 $(RAW_CXX_TARGET_EXPORTS) \[+
1065 $(NORMAL_TARGET_EXPORTS) \[+
1067 echo "Doing [+make_target+] in $(TARGET_SUBDIR)/[+module+]" ; \
1068 for flag in $(EXTRA_TARGET_FLAGS); do \
1069 eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
1071 (cd $(TARGET_SUBDIR)/[+module+] && \
1072 $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
1073 "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
1074 "RANLIB=$${RANLIB}" \
1075 "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
1076 [+extra_make_flags+] [+make_target+]) \
1079 @endif target-[+module+]
1080 [+ ENDFOR recursive_targets +]
1081 [+ ENDFOR target_modules +]
1087 @if gcc-no-bootstrap
1088 # GCC has some more recursive targets, which trigger the old
1089 # (but still current, until the toplevel bootstrap project
1090 # is finished) compiler bootstrapping rules.
1092 GCC_STRAP_TARGETS = bootstrap bootstrap-lean bootstrap2 bootstrap2-lean bootstrap3 bootstrap3-lean bootstrap4 bootstrap4-lean bubblestrap quickstrap cleanstrap restrap
1093 .PHONY: $(GCC_STRAP_TARGETS)
1094 $(GCC_STRAP_TARGETS): all-prebootstrap configure-gcc
1095 @r=`${PWD_COMMAND}`; export r; \
1096 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1098 echo "Bootstrapping the compiler"; \
1099 $(RPATH_ENVVAR)=`echo "$(TARGET_LIB_PATH)$$$(RPATH_ENVVAR)" | sed 's,:[ :]*,:,g;s,^[ :]*,,;s,:*$$,,'`; export $(RPATH_ENVVAR); \
1100 cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) $@
1101 @r=`${PWD_COMMAND}`; export r; \
1102 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1104 *bootstrap4-lean ) \
1105 msg="Comparing stage3 and stage4 of the compiler"; \
1106 compare=compare3-lean ;; \
1108 msg="Comparing stage3 and stage4 of the compiler"; \
1109 compare=compare3 ;; \
1111 msg="Comparing stage2 and stage3 of the compiler"; \
1112 compare=compare-lean ;; \
1114 msg="Comparing stage2 and stage3 of the compiler"; \
1115 compare=compare ;; \
1119 cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) $$compare
1120 @r=`${PWD_COMMAND}`; export r; \
1121 s=`cd $(srcdir); ${PWD_COMMAND}` ; export s; \
1122 echo "Building runtime libraries"; \
1123 $(MAKE) $(RECURSE_FLAGS_TO_PASS) all
1125 profiledbootstrap: all-prebootstrap configure-gcc
1126 @r=`${PWD_COMMAND}`; export r; \
1127 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1129 $(RPATH_ENVVAR)=`echo "$(TARGET_LIB_PATH)$$$(RPATH_ENVVAR)" | sed 's,:[ :]*,:,g;s,^[ :]*,,;s,:*$$,,'`; export $(RPATH_ENVVAR); \
1130 echo "Bootstrapping training compiler"; \
1131 cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) stageprofile_build
1132 @r=`${PWD_COMMAND}`; export r; \
1133 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1135 echo "Building feedback based compiler"; \
1136 cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) stagefeedback_build
1137 @r=`${PWD_COMMAND}`; export r; \
1138 s=`cd $(srcdir); ${PWD_COMMAND}` ; export s; \
1139 echo "Building runtime libraries"; \
1140 $(MAKE) $(RECURSE_FLAGS_TO_PASS) all
1143 cross: all-build all-gas all-ld
1144 @r=`${PWD_COMMAND}`; export r; \
1145 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1147 echo "Building the C and C++ compiler"; \
1148 cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) LANGUAGES="c c++"
1149 @r=`${PWD_COMMAND}`; export r; \
1150 s=`cd $(srcdir); ${PWD_COMMAND}` ; export s; \
1151 echo "Building runtime libraries"; \
1152 $(MAKE) $(RECURSE_FLAGS_TO_PASS) LANGUAGES="c c++" all
1153 @endif gcc-no-bootstrap
1156 .PHONY: check-gcc-c++
1158 @if [ -f ./gcc/Makefile ] ; then \
1159 r=`${PWD_COMMAND}`; export r; \
1160 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1162 (cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) check-c++); \
1168 check-c++: check-target-libstdc++-v3 check-gcc-c++
1170 # Install the gcc headers files, but not the fixed include files,
1171 # which Cygnus is not allowed to distribute. This rule is very
1172 # dependent on the workings of the gcc Makefile.in.
1173 .PHONY: gcc-no-fixedincludes
1174 gcc-no-fixedincludes:
1175 @if [ -f ./gcc/Makefile ]; then \
1176 rm -rf gcc/tmp-include; \
1177 mv gcc/include gcc/tmp-include 2>/dev/null; \
1178 mkdir gcc/include; \
1179 cp $(srcdir)/gcc/gsyslimits.h gcc/include/syslimits.h; \
1180 touch gcc/stmp-fixinc gcc/include/fixed; \
1181 rm -f gcc/stmp-headers gcc/stmp-int-hdrs; \
1182 r=`${PWD_COMMAND}`; export r; \
1183 s=`cd $(srcdir); ${PWD_COMMAND}` ; export s; \
1186 $(MAKE) $(GCC_FLAGS_TO_PASS) install); \
1187 rm -rf gcc/include; \
1188 mv gcc/tmp-include gcc/include 2>/dev/null; \
1192 # ---------------------
1193 # GCC bootstrap support
1194 # ---------------------
1196 # We track the current stage (the one in 'gcc') in the stage_current file.
1197 # stage_last instead tracks the stage that was built last. These targets
1198 # are dummy when toplevel bootstrap is not active.
1203 @[ -f stage_current ] || $(MAKE) `cat stage_last`-start
1204 @endif gcc-bootstrap
1209 @$(MAKE) `cat stage_current`-end
1210 @endif gcc-bootstrap
1212 # We name the build directories for the various stages "stage1-gcc",
1213 # "stage2-gcc","stage3-gcc", etc.
1215 # Since the 'compare' process will fail (on debugging information) if any
1216 # directory names are different, we need to link the gcc directory for
1217 # the previous stage to a constant name ('gcc-prev'), and to make the name of
1218 # the build directories constant as well. For the latter, we use naked names
1219 # like 'gcc', because the scripts in that directory assume it. We use
1220 # mv on platforms where symlinks to directories do not work or are not
1223 # At the end of the bootstrap, a symlink to 'stage3-gcc' named 'gcc' must
1224 # be kept, so that libraries can find it. Ick!
1226 # It would be best to preinstall gcc into a staging area (and in the
1227 # future, gather there all prebootstrap packages). This would allow
1228 # assemblers and linkers can be bootstrapped as well as the compiler
1229 # (both in a combined tree, or separately). This however requires some
1230 # change to the gcc driver, again in order to avoid comparison failures.
1232 # Bugs: This is crippled when doing parallel make, the `make all-host'
1233 # and `make all-target' phases can be parallelized.
1236 # 'touch' doesn't work right on some platforms.
1237 STAMP = echo timestamp >
1239 # Only build the C compiler for stage1, because that is the only one that
1240 # we can guarantee will build with the native compiler, and also it is the
1241 # only thing useful for building stage2. STAGE1_CFLAGS (via CFLAGS),
1242 # MAKEINFO and MAKEINFOFLAGS are explicitly passed here to make them
1243 # overrideable (for a bootstrap build stage1 also builds gcc.info).
1245 STAGE1_CFLAGS=@stage1_cflags@
1246 STAGE1_LANGUAGES=@stage1_languages@
1248 # We only want to compare .o files, so set this!
1251 # Flags to pass to stage2 and later makes.
1252 POSTSTAGE1_FLAGS_TO_PASS = \
1253 CC="$${CC}" CC_FOR_BUILD="$${CC_FOR_BUILD}" \
1254 STAGE_PREFIX=$$r/stage[+prev+]-gcc/ \
1255 CFLAGS="$(BOOT_CFLAGS)" \
1259 # * We force-disable intermodule optimizations, even if
1260 # --enable-intermodule was passed, since the installed compiler probably
1261 # can't handle them. Luckily, autoconf always respects
1262 # the last argument when conflicting --enable arguments are passed.
1263 # * Likewise, we force-disable coverage flags, since the installed compiler
1264 # probably has never heard of them.
1265 # * We build only C (and possibly Ada).
1267 [+ FOR bootstrap-stage +]
1268 .PHONY: stage[+id+]-start stage[+id+]-end
1271 @[ -f stage_current ] && $(MAKE) `cat stage_current`-end || : ; \
1272 echo stage[+id+] > stage_current ; \
1273 echo stage[+id+] > stage_last; \
1274 $(mkinstalldirs) $(HOST_SUBDIR)[+
1275 FOR host_modules +][+ IF bootstrap +]
1277 @cd $(HOST_SUBDIR); [ -d stage[+id+]-[+module+] ] || \
1278 mkdir stage[+id+]-[+module+]; \
1279 set stage[+id+]-[+module+] [+module+] ; \
1280 @CREATE_LINK_TO_DIR@ [+ IF prev +] ; \
1281 set stage[+prev+]-[+module+] prev-[+module+] ; \
1282 @CREATE_LINK_TO_DIR@ [+ ENDIF prev +]
1283 @endif [+ module +][+ ENDIF bootstrap +][+ ENDFOR host_modules +]
1286 @rm -f stage_current[+ FOR host_modules +][+ IF bootstrap +]
1288 @cd $(HOST_SUBDIR); set [+module+] stage[+id+]-[+module+] ; \
1289 @UNDO_LINK_TO_DIR@ [+ IF prev +] ; \
1290 set prev-[+module+] stage[+prev+]-[+module+] ; \
1291 @UNDO_LINK_TO_DIR@ [+ ENDIF prev +]
1292 @endif [+ module +][+ ENDIF bootstrap +][+ ENDFOR host_modules +]
1294 # Bubble a bugfix through all the stages up to stage [+id+]. They
1295 # are remade, but not reconfigured. The next stage (if any) will not
1296 # be reconfigured as well.
1297 .PHONY: stage[+id+]-bubble
1298 stage[+id+]-bubble:: [+ IF prev +]stage[+prev+]-bubble[+ ENDIF +][+IF lean +]
1299 @bootstrap_lean@-rm -rf stage[+lean+]-* ; $(STAMP) stage[+lean+]-lean[+ ENDIF lean +]
1300 @if test -f stage[+id+]-lean [+
1301 IF prev +]|| test -f stage[+prev+]-lean [+ ENDIF prev +] ; then \
1302 echo Skipping rebuild of stage[+id+] ; \
1304 $(MAKE) $(RECURSE_FLAGS_TO_PASS) NOTPARALLEL= all-stage[+id+]; \
1307 .PHONY: all-stage[+id+] clean-stage[+id+]
1308 all-stage[+id+]: [+ FOR host_modules +][+ IF bootstrap +]\
1309 maybe-all-stage[+id+]-[+module+][+
1310 ENDIF bootstrap+] [+ ENDFOR host_modules +]
1312 do-clean: clean-stage[+id+]
1313 clean-stage[+id+]: [+ FOR host_modules +][+ IF bootstrap +]\
1314 maybe-clean-stage[+id+]-[+module+][+
1315 ENDIF bootstrap+] [+ ENDFOR host_modules +]
1317 [+ FOR host_modules +][+ IF bootstrap +]
1318 .PHONY: configure-stage[+id+]-[+module+] maybe-configure-stage[+id+]-[+module+]
1319 .PHONY: all-stage[+id+]-[+module+] maybe-all-stage[+id+]-[+module+]
1320 .PHONY: clean-stage[+id+]-[+module+] maybe-clean-stage[+id+]-[+module+]
1322 maybe-configure-stage[+id+]-[+module+]:
1323 maybe-all-stage[+id+]-[+module+]:
1324 maybe-clean-stage[+id+]-[+module+]:
1326 @if [+module+]-bootstrap
1327 maybe-configure-stage[+id+]-[+module+]: configure-stage[+id+]-[+module+]
1328 configure-stage[+id+]-[+module+]:
1329 @$(MAKE) stage[+id+]-start
1330 @[ -f [+module+]/Makefile ] && exit 0 || : ; \
1331 r=`${PWD_COMMAND}`; export r; \
1332 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; [+ IF prev +] \
1333 $(STAGE_HOST_EXPORTS) [+ ELSE prev +] \
1334 $(HOST_EXPORTS) [+ ENDIF prev +] \
1335 echo Configuring stage [+id+] in [+module+] ; \
1336 cd $(HOST_SUBDIR)/[+module+] || exit 1; \
1338 /* | [A-Za-z]:[\\/]*) topdir=$(srcdir) ;; \
1339 *) topdir=`echo $(HOST_SUBDIR)/[+module+]/ | \
1340 sed -e 's,\./,,g' -e 's,[^/]*/,../,g' `$(srcdir) ;; \
1342 srcdiroption="--srcdir=$${topdir}/[+module+]"; \
1343 libsrcdir="$$s/[+module+]"; \
1344 $(SHELL) $${libsrcdir}/configure \
1345 $(HOST_CONFIGARGS) $${srcdiroption} \
1346 [+stage_configure_flags+] [+extra_configure_flags+]
1348 maybe-all-stage[+id+]-[+module+]: all-stage[+id+]-[+module+]
1349 all-stage[+id+]-[+module+]: configure-stage[+id+]-[+module+]
1350 @$(MAKE) stage[+id+]-start
1351 @r=`${PWD_COMMAND}`; export r; \
1352 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; [+ IF prev +] \
1353 $(STAGE_HOST_EXPORTS) [+ ELSE prev +] \
1354 $(HOST_EXPORTS) [+ ENDIF prev +] \
1355 cd $(HOST_SUBDIR)/[+module+] && \
1356 $(MAKE) $(FLAGS_TO_PASS) [+ IF prev +] \
1357 $(POSTSTAGE1_FLAGS_TO_PASS) [+ ENDIF prev +] \
1358 [+stage_make_flags+] [+extra_make_flags+]
1360 maybe-clean-stage[+id+]-[+module+]: clean-stage[+id+]-[+module+]
1361 clean-stage[+id+]-[+module+]:
1362 @[ -f [+module+]/Makefile ] || [ -f stage[+id+]-[+module+]/Makefile ] \
1364 [ -f [+module+]/Makefile ] || $(MAKE) stage[+id+]-start ; \
1365 cd $(HOST_SUBDIR)/[+module+] && \
1366 $(MAKE) $(FLAGS_TO_PASS) [+ IF prev +] \
1367 $(POSTSTAGE1_FLAGS_TO_PASS) [+ ENDIF prev +] \
1368 [+stage_make_flags+] [+extra_make_flags+] clean
1369 @endif [+module+]-bootstrap
1371 [+ ENDIF bootstrap +][+ ENDFOR host_modules +]
1373 # FIXME: Will not need to be conditional when toplevel bootstrap is the
1374 # only possibility, but now it conflicts with no-bootstrap rules
1376 [+ IF compare-target +]
1378 @if test -f stage[+prev+]-lean; then \
1379 echo Cannot compare object files as stage [+prev+] was deleted. ; \
1382 [ -f stage_current ] && $(MAKE) `cat stage_current`-end || : ; \
1383 @r=`${PWD_COMMAND}`; export r; \
1384 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1385 rm -f .bad_compare ; \
1386 cd stage[+id+]-gcc; \
1387 files=`find . -name "*$(objext)" -print` ; \
1389 for file in $${files} ; do \
1390 f1=$$r/stage[+prev+]-gcc/$$file; f2=$$r/stage[+id+]-gcc/$$file; \
1391 @do_compare@ > /dev/null 2>&1; \
1392 test $$? -eq 1 && echo $$file differs >> .bad_compare || true; \
1394 if [ -f .bad_compare ]; then \
1395 echo "Bootstrap comparison failure!"; \
1401 $(STAMP) [+compare-target+][+ IF prev +]
1402 @bootstrap_lean@-rm -rf stage[+prev+]-* ; $(STAMP) stage[+prev+]-lean[+ ENDIF prev +]
1403 [+ ENDIF compare-target +]
1405 [+ IF bootstrap-target +]
1406 .PHONY: [+bootstrap-target+]
1407 [+bootstrap-target+]: stage[+id+]-bubble [+compare-target+] all
1408 [+ ENDIF bootstrap-target +]
1410 # Rules to wipe a stage and all the following ones, also used for cleanstrap
1411 [+ IF prev +]distclean-stage[+prev+]:: distclean-stage[+id+] [+ ENDIF prev +]
1412 .PHONY: distclean-stage[+id+]
1413 distclean-stage[+id+]::
1414 [ -f stage_current ] && $(MAKE) `cat stage_current`-end || :
1415 rm -rf stage[+id+]-* [+
1416 IF compare-target +][+compare-target+] [+ ENDIF compare-target +]
1418 [+ IF cleanstrap-target +]
1419 .PHONY: [+cleanstrap-target+]
1420 [+cleanstrap-target+]: distclean [+bootstrap-target+]
1421 [+ ENDIF cleanstrap-target +]
1422 @endif gcc-bootstrap
1424 [+ ENDFOR bootstrap-stage +]
1426 stagefeedback-start::
1427 @r=`${PWD_COMMAND}`; export r; \
1428 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1429 cd stageprofile-gcc && \
1430 { find . -type d | sort | sed 's,.*,$(SHELL) '"$$s"'/mkinstalldirs "../gcc/&",' | $(SHELL); } && \
1431 { find . -name '*.*da' | sed 's,.*,$(LN) -f "&" "../gcc/&",' | $(SHELL); }
1433 # FIXME: Will not need to be conditional when toplevel bootstrap is the
1434 # only possibility, but now it conflicts with no-bootstrap rules
1437 @r=`${PWD_COMMAND}`; export r; \
1438 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1440 echo "Bootstrapping the compiler"; \
1441 $(MAKE) stageprofile-bubble distclean-stagefeedback
1442 @r=`${PWD_COMMAND}`; export r; \
1443 s=`cd $(srcdir); ${PWD_COMMAND}` ; export s; \
1444 echo "Building runtime libraries and training compiler"; \
1445 $(MAKE) $(BASE_FLAGS_TO_PASS) $(RECURSE_FLAGS) all
1446 @r=`${PWD_COMMAND}`; export r; \
1447 s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
1449 echo "Building feedback based compiler"; \
1450 $(MAKE) stagefeedback-bubble stagefeedback-end
1451 @endif gcc-bootstrap
1454 NOTPARALLEL = .NOTPARALLEL
1456 do-distclean: distclean-stage1
1457 @endif gcc-bootstrap
1459 # --------------------------------------
1460 # Dependencies between different modules
1461 # --------------------------------------
1463 # Generic dependencies for target modules on host stuff, especially gcc
1464 [+ FOR target_modules +]
1465 configure-target-[+module+]: maybe-all-gcc
1466 [+ ENDFOR target_modules +]
1468 [+ FOR lang_env_dependencies +]
1469 configure-target-[+module+]: maybe-all-target-newlib maybe-all-target-libgloss
1470 [+ IF cxx +]configure-target-[+module+]: maybe-all-target-libstdc++-v3
1471 [+ ENDIF cxx +][+ ENDFOR lang_env_dependencies +]
1473 # There are two types of dependencies here: 'hard' dependencies, where one
1474 # module simply won't build without the other; and 'soft' dependencies, where
1475 # if the depended-on module is missing, the depending module will do without
1476 # or find a substitute somewhere (perhaps installed). Soft dependencies
1477 # are made here to depend on a 'maybe-' target. If you're not sure,
1478 # it's safer to use a soft dependency.
1480 [+ ;; These Scheme functions build the bulk of the dependencies.
1481 ;; dep-target builds a string like "maybe-all-MODULE_KIND-gcc",
1482 ;; where "maybe-" is only included if HARD is true, and all-gcc
1483 ;; is taken from VAR-NAME.
1484 (define dep-target (lambda (module-kind var-name hard)
1486 (if hard "" "maybe-")
1487 (dep-subtarget var-name)
1489 (dep-module var-name)
1492 ;; make-dep builds a dependency from the MODULE and ON AutoGen vars.
1493 (define make-dep (lambda (module-kind on-kind)
1495 (dep-target module-kind "module" #t) ": "
1496 (dep-target on-kind "on" (exist? "hard")))))
1498 ;; dep-subtarget extracts everything up to the first dash in the given
1499 ;; AutoGen variable, for example it extracts "all-" out of "all-gcc".
1500 (define dep-subtarget (lambda (var-name)
1501 (substring (get var-name) 0 (+ 1 (string-index (get var-name) #\-)))))
1503 ;; dep-module extracts everything up to the first dash in the given
1504 ;; AutoGen variable, for example it extracts "gcc" out of "all-gcc".
1505 (define dep-module (lambda (var-name)
1506 (substring (get var-name) (+ 1 (string-index (get var-name) #\-)))))
1508 ;; dep-stage builds a string for the prefix of a bootstrap stage.
1509 (define dep-stage (lambda ()
1515 ;; dep-maybe is the same as the AutoGen expression "- hard 'maybe-'"
1516 ;; but is written in Scheme.
1517 (define dep-maybe (lambda ()
1518 (if (exist? "hard") "" "maybe-")))
1520 ;; dep-kind returns "normal" if the dependency is on an "install" target,
1521 ;; or if either module is not bootstrapped. It returns "bootstrap" for
1522 ;; configure or build dependencies between bootstrapped modules; it returns
1523 ;; "prebootstrap" for configure or build dependencies of bootstrapped
1524 ;; modules on a build module (e.g. all-gcc on all-build-bison). All this
1525 ;; is only necessary for host modules.
1526 (define dep-kind (lambda ()
1527 (if (and (hash-ref boot-modules (dep-module "module"))
1528 (=* (dep-module "on") "build-"))
1531 (if (or (= (dep-subtarget "on") "install-")
1532 (=* (dep-module "on") "target-")
1533 (not (hash-ref boot-modules (dep-module "module")))
1534 (not (hash-ref boot-modules (dep-module "on"))))
1538 ;; We now build the hash table that is used by dep-kind.
1539 (define boot-modules (make-hash-table 113))
1542 [+ FOR host_modules +][+
1543 (if (exist? "bootstrap")
1544 (hash-create-handle! boot-modules (get "module") #t))
1545 "" +][+ ENDFOR host_modules +]
1547 # With all the machinery above in place, it is pretty easy to generate
1548 # dependencies. Host dependencies are a bit more complex because we have
1549 # to check for bootstrap/prebootstrap dependencies. To resolve
1550 # prebootstrap dependencies, prebootstrap modules are gathered in
1552 [+ FOR dependencies +][+ (make-dep "" "") +]
1553 [+ CASE (dep-kind) +]
1554 [+ == "prebootstrap"
1555 +][+ FOR bootstrap_stage +]
1556 [+ (make-dep (dep-stage) "") +][+
1557 ENDFOR bootstrap_stage +]
1558 all-prebootstrap: [+ (dep-target "" "on" (exist? "hard")) +]
1560 +][+ FOR bootstrap_stage +]
1561 [+ (make-dep (dep-stage) (dep-stage)) +][+
1562 ENDFOR bootstrap_stage +]
1564 ENDFOR dependencies +]
1566 # Non-toplevel bootstrap rules must depend on several packages, to be built
1567 # before gcc. Another wart that will go away, hopefully soon.
1568 @if gcc-no-bootstrap
1569 [+ FOR host_modules +][+
1570 IF (and (not (= (get "module") "gcc"))
1571 (hash-ref boot-modules (get "module"))) +]
1572 all-prebootstrap: maybe-all-[+module+][+
1574 ENDFOR host_modules +]
1575 @endif gcc-no-bootstrap
1578 all-gdb: $(gdbnlmrequirements) $(GDB_TK)
1580 # Serialization dependencies. Host configures don't work well in parallel to
1581 # each other, due to contention over config.cache. Target configures and
1582 # build configures are similar.
1583 @serialization_dependencies@
1585 # --------------------------------
1586 # Regenerating top level configury
1587 # --------------------------------
1589 # Multilib.out tells target dirs what multilibs they should build.
1590 # There is really only one copy. We use the 'timestamp' method to
1591 # work around various timestamp bugs on some systems.
1592 # We use move-if-change so that it's only considered updated when it
1593 # actually changes, because it has to depend on a phony target.
1594 multilib.out: maybe-all-gcc
1595 @r=`${PWD_COMMAND}`; export r; \
1596 echo "Checking multilib configuration..."; \
1597 $(CC_FOR_TARGET) --print-multi-lib > multilib.tmp 2> /dev/null ; \
1598 $(SHELL) $(srcdir)/move-if-change multilib.tmp multilib.out ; \
1600 # Rebuilding Makefile.in, using autogen.
1602 $(srcdir)/Makefile.in: @MAINT@ $(srcdir)/Makefile.tpl $(srcdir)/Makefile.def
1603 cd $(srcdir) && $(AUTOGEN) Makefile.def
1605 # Rebuilding Makefile.
1606 Makefile: $(srcdir)/Makefile.in config.status
1607 CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
1609 config.status: configure
1610 CONFIG_SHELL="$(SHELL)" $(SHELL) ./config.status --recheck
1612 # Rebuilding configure.
1614 $(srcdir)/configure: @MAINT@ $(srcdir)/configure.in $(srcdir)/config/acx.m4
1615 cd $(srcdir) && $(AUTOCONF)
1617 # ------------------------------
1618 # Special directives to GNU Make
1619 # ------------------------------
1621 # Don't pass command-line variables to submakes.
1625 # end of Makefile.in