2002-09-25 Nathanael Nerode <neroden@gcc.gnu.org>
[deliverable/binutils-gdb.git] / Makefile.in
CommitLineData
405ea7a0
NN
1
2# Makefile.in is generated from Makefile.tpl by 'autogen Makefile.def'.
252b5132
RH
3#
4# Makefile for directory with subdirs to build.
5cec67bf 5# Copyright (C) 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
d5de0a84 6# 1999, 2000, 2001, 2002 Free Software Foundation
252b5132
RH
7#
8# This file is free software; you can redistribute it and/or modify
9# it under the terms of the GNU General Public License as published by
10# the Free Software Foundation; either version 2 of the License, or
11# (at your option) any later version.
12#
13# This program is distributed in the hope that it will be useful,
14# but WITHOUT ANY WARRANTY; without even the implied warranty of
15# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16# GNU General Public License for more details.
17#
18# You should have received a copy of the GNU General Public License
19# along with this program; if not, write to the Free Software
20# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
21#
22
80413487 23# Tell GNU make 3.79 not to run the top level in parallel. This
3daeddf6
RH
24# prevents contention for $builddir/$target/config.cache, as well
25# as minimizing scatter in file system caches.
80413487
RH
26NOTPARALLEL = .NOTPARALLEL
27$(NOTPARALLEL):
3daeddf6 28
252b5132
RH
29srcdir = .
30
31prefix = /usr/local
32exec_prefix = $(prefix)
33
34bindir=${exec_prefix}/bin
35sbindir=${exec_prefix}/sbin
36libexecdir=${exec_prefix}/libexec
37datadir=${prefix}/share
38sysconfdir=${prefix}/etc
39sharedstatedir=${prefix}/com
40localstatedir=${prefix}/var
41libdir=${exec_prefix}/lib
42includedir=${prefix}/include
43oldincludedir=/usr/include
44infodir=${prefix}/info
45mandir=${prefix}/man
46gxx_include_dir=${includedir}/g++
47
ba73c63f
JM
48tooldir = $(exec_prefix)/$(target_alias)
49build_tooldir = $(exec_prefix)/$(target_alias)
252b5132
RH
50
51program_transform_name =
52
53man1dir = $(mandir)/man1
54man2dir = $(mandir)/man2
55man3dir = $(mandir)/man3
56man4dir = $(mandir)/man4
57man5dir = $(mandir)/man5
58man6dir = $(mandir)/man6
59man7dir = $(mandir)/man7
60man8dir = $(mandir)/man8
61man9dir = $(mandir)/man9
62infodir = $(prefix)/info
63includedir = $(prefix)/include
64# Directory in which the compiler finds executables, libraries, etc.
65libsubdir = $(libdir)/gcc-lib/$(target_alias)/$(gcc_version)
66GDB_NLM_DEPS =
67
68SHELL = /bin/sh
69
d5de0a84
NC
70# pwd command to use. Allow user to override default by setting PWDCMD in
71# the environment to account for automounters. The make variable must not
72# be called PWDCMD, otherwise the value set here is passed to make
73# subprocesses and overrides the setting from the user's environment.
74PWD = $${PWDCMD-pwd}
75
252b5132
RH
76# INSTALL_PROGRAM_ARGS is changed by configure.in to use -x for a
77# cygwin host.
78INSTALL_PROGRAM_ARGS =
79
80INSTALL = $(SHELL) $$s/install-sh -c
81INSTALL_PROGRAM = $(INSTALL) $(INSTALL_PROGRAM_ARGS)
82INSTALL_SCRIPT = $(INSTALL)
83INSTALL_DATA = $(INSTALL) -m 644
84
85INSTALL_DOSREL = install-dosrel-fake
86
87AS = as
88AR = ar
89AR_FLAGS = rc
90CC = cc
91
92# Special variables passed down in EXTRA_GCC_FLAGS. They are defined
93# here so that they can be overridden by Makefile fragments.
94HOST_CC = $(CC_FOR_BUILD)
27f15fdd
DD
95BUILD_PREFIX =
96BUILD_PREFIX_1 = loser-
252b5132
RH
97
98# These flag values are normally overridden by the configure script.
99CFLAGS = -g
100CXXFLAGS = -g -O2
101
c363de44 102LDFLAGS =
252b5132 103LIBCFLAGS = $(CFLAGS)
75205f78 104CFLAGS_FOR_BUILD = $(CFLAGS)
6c5e141a
DD
105# During gcc bootstrap, if we use some random cc for stage1 then
106# CFLAGS will be just -g. We want to ensure that TARGET libraries
107# (which we know are built with gcc) are built with optimizations so
108# prepend -O2 when setting CFLAGS_FOR_TARGET.
109CFLAGS_FOR_TARGET = -O2 $(CFLAGS)
252b5132
RH
110LDFLAGS_FOR_TARGET =
111LIBCFLAGS_FOR_TARGET = $(CFLAGS_FOR_TARGET)
112PICFLAG =
113PICFLAG_FOR_TARGET =
114
252b5132
RH
115CXX = c++
116
117# Use -O2 to stress test the compiler.
ba73c63f 118LIBCXXFLAGS = $(CXXFLAGS) -fno-implicit-templates
252b5132 119CXXFLAGS_FOR_TARGET = $(CXXFLAGS)
ba73c63f 120LIBCXXFLAGS_FOR_TARGET = $(CXXFLAGS_FOR_TARGET) -fno-implicit-templates
252b5132 121
252b5132
RH
122DLLTOOL = dlltool
123WINDRES = windres
124
125NM = nm
126
127LD = ld
128
c376f4ed 129BZIPPROG = bzip2
b35ece4e 130MD5PROG = md5sum
252b5132
RH
131
132# These values are substituted by configure.
133DEFAULT_YACC = yacc
134DEFAULT_LEX = lex
135DEFAULT_M4 = m4
136
137BISON = `if [ -f $$r/bison/bison ] ; then \
138 echo $$r/bison/bison -L $$s/bison/ ; \
139 else \
140 echo bison ; \
141 fi`
142
143YACC = `if [ -f $$r/bison/bison ] ; then \
144 echo $$r/bison/bison -y -L $$s/bison/ ; \
145 elif [ -f $$r/byacc/byacc ] ; then \
146 echo $$r/byacc/byacc ; \
147 else \
148 echo ${DEFAULT_YACC} ; \
149 fi`
150
151LEX = `if [ -f $$r/flex/flex ] ; \
152 then echo $$r/flex/flex ; \
153 else echo ${DEFAULT_LEX} ; fi`
154
155M4 = `if [ -f $$r/m4/m4 ] ; \
156 then echo $$r/m4/m4 ; \
157 else echo ${DEFAULT_M4} ; fi`
158
f08fa01d
HPN
159# For an installed makeinfo, we require it to be from texinfo 4 or
160# higher, else we use the "missing" dummy.
081ff160 161MAKEINFO = `if [ -f $$r/texinfo/makeinfo/makeinfo ] ; \
252b5132 162 then echo $$r/texinfo/makeinfo/makeinfo ; \
f08fa01d
HPN
163 else if (makeinfo --version \
164 | egrep 'texinfo[^0-9]*([1-3][0-9]|[4-9])') >/dev/null 2>&1; \
165 then echo makeinfo; else echo $$s/missing makeinfo; fi; fi`
252b5132
RH
166
167# This just becomes part of the MAKEINFO definition passed down to
168# sub-makes. It lets flags be given on the command line while still
169# using the makeinfo from the object tree.
170MAKEINFOFLAGS =
171
172EXPECT = `if [ -f $$r/expect/expect ] ; \
173 then echo $$r/expect/expect ; \
174 else echo expect ; fi`
175
176RUNTEST = `if [ -f $$s/dejagnu/runtest ] ; \
177 then echo $$s/dejagnu/runtest ; \
178 else echo runtest ; fi`
179
180
181# compilers to use to create programs which must be run in the build
182# environment.
183CC_FOR_BUILD = $(CC)
184CXX_FOR_BUILD = $(CXX)
185
186SUBDIRS = "this is set via configure, don't edit this"
187OTHERS =
188
189# This is set by the configure script to the list of directories which
190# should be built using the target tools.
c74222f7 191TARGET_CONFIGDIRS = libiberty libgloss $(SPECIAL_LIBS) newlib winsup opcodes libf2c libobjc
252b5132
RH
192
193# Target libraries are put under this directory:
194# Changed by configure to $(target_alias) if cross.
195TARGET_SUBDIR = .
196
49b7683b
DD
197BUILD_CONFIGDIRS = libiberty
198BUILD_SUBDIR = .
199
200# This is set by the configure script to the arguments to use when configuring
201# directories built for the target.
202TARGET_CONFIGARGS =
203
204# This is set by the configure script to the arguments to use when configuring
205# directories built for the build system.
206BUILD_CONFIGARGS =
252b5132
RH
207
208# This is set by configure to REALLY_SET_LIB_PATH if --enable-shared
209# was used.
210SET_LIB_PATH =
211
212# This is the name of the environment variable used for the path to
213# the libraries. This may be changed by configure.in.
214RPATH_ENVVAR = LD_LIBRARY_PATH
215
0da52010
AO
216# This is the list of directories that may be needed in RPATH_ENVVAR
217# so that programs built for the host machine work.
218HOST_LIB_PATH = $$r/bfd:$$r/opcodes
219
220# This is the list of directories that may be needed in RPATH_ENVVAR
221# so that prorgams built for the target machine work.
75205f78 222TARGET_LIB_PATH = $$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs:
0da52010 223
252b5132 224# configure.in sets SET_LIB_PATH to this if --enable-shared was used.
0da52010
AO
225# Some platforms don't like blank entries, so we remove duplicate,
226# leading and trailing colons.
252b5132 227REALLY_SET_LIB_PATH = \
0da52010 228 $(RPATH_ENVVAR)=`echo "$(HOST_LIB_PATH):$(TARGET_LIB_PATH):$$$(RPATH_ENVVAR)" | sed 's,::*,:,g;s,^:*,,;s,:*$$,,'`; export $(RPATH_ENVVAR);
252b5132
RH
229
230ALL = all.normal
231INSTALL_TARGET = installdirs \
232 install-gcc \
233 $(INSTALL_MODULES) \
234 $(INSTALL_TARGET_MODULES) \
235 $(INSTALL_X11_MODULES) \
236 $(INSTALL_DOSREL)
237
238INSTALL_TARGET_CROSS = installdirs \
239 install-gcc-cross \
240 $(INSTALL_MODULES) \
241 $(INSTALL_TARGET_MODULES) \
242 $(INSTALL_X11_MODULES) \
243 $(INSTALL_DOSREL)
244
9e449d3e
AO
245# Should be substed by configure.in
246FLAGS_FOR_TARGET =
247CC_FOR_TARGET =
9e449d3e 248CXX_FOR_TARGET =
dec0cb0c 249CXX_FOR_TARGET_FOR_RECURSIVE_MAKE =
75205f78 250GCJ_FOR_TARGET =
252b5132 251
9e449d3e 252# If GCC_FOR_TARGET is not overriden on the command line, then this
252b5132
RH
253# variable is passed down to the gcc Makefile, where it is used to
254# build libgcc2.a. We define it here so that it can itself be
255# overridden on the command line.
a08bafb5 256GCC_FOR_TARGET = $(STAGE_CC_WRAPPER) $$r/gcc/xgcc -B$$r/gcc/ $(FLAGS_FOR_TARGET)
252b5132
RH
257
258AS_FOR_TARGET = ` \
259 if [ -f $$r/gas/as-new ] ; then \
260 echo $$r/gas/as-new ; \
dc70af01
AO
261 elif [ -f $$r/gcc/xgcc ]; then \
262 $(CC_FOR_TARGET) -print-prog-name=as ; \
252b5132 263 else \
3f152009 264 if [ '$(host_canonical)' = '$(target_canonical)' ] ; then \
252b5132
RH
265 echo $(AS); \
266 else \
267 t='$(program_transform_name)'; echo as | sed -e 's/x/x/' $$t ; \
268 fi; \
269 fi`
270
271LD_FOR_TARGET = ` \
272 if [ -f $$r/ld/ld-new ] ; then \
273 echo $$r/ld/ld-new ; \
dc70af01
AO
274 elif [ -f $$r/gcc/xgcc ]; then \
275 $(CC_FOR_TARGET) -print-prog-name=ld ; \
252b5132 276 else \
3f152009 277 if [ '$(host_canonical)' = '$(target_canonical)' ] ; then \
252b5132
RH
278 echo $(LD); \
279 else \
280 t='$(program_transform_name)'; echo ld | sed -e 's/x/x/' $$t ; \
281 fi; \
282 fi`
283
284DLLTOOL_FOR_TARGET = ` \
285 if [ -f $$r/binutils/dlltool ] ; then \
286 echo $$r/binutils/dlltool ; \
287 else \
3f152009 288 if [ '$(host_canonical)' = '$(target_canonical)' ] ; then \
252b5132
RH
289 echo $(DLLTOOL); \
290 else \
291 t='$(program_transform_name)'; echo dlltool | sed -e 's/x/x/' $$t ; \
292 fi; \
293 fi`
294
295WINDRES_FOR_TARGET = ` \
296 if [ -f $$r/binutils/windres ] ; then \
297 echo $$r/binutils/windres ; \
298 else \
3f152009 299 if [ '$(host_canonical)' = '$(target_canonical)' ] ; then \
252b5132
RH
300 echo $(WINDRES); \
301 else \
302 t='$(program_transform_name)'; echo windres | sed -e 's/x/x/' $$t ; \
303 fi; \
304 fi`
305
306AR_FOR_TARGET = ` \
307 if [ -f $$r/binutils/ar ] ; then \
308 echo $$r/binutils/ar ; \
309 else \
3f152009 310 if [ '$(host_canonical)' = '$(target_canonical)' ] ; then \
252b5132
RH
311 echo $(AR); \
312 else \
313 t='$(program_transform_name)'; echo ar | sed -e 's/x/x/' $$t ; \
314 fi; \
315 fi`
316
317RANLIB_FOR_TARGET = ` \
318 if [ -f $$r/binutils/ranlib ] ; then \
319 echo $$r/binutils/ranlib ; \
320 else \
3f152009
AO
321 if [ '$(host_canonical)' = '$(target_canonical)' ] ; then \
322 if [ x'$(RANLIB)' != x ]; then \
323 echo $(RANLIB); \
324 else \
325 echo ranlib; \
326 fi; \
252b5132
RH
327 else \
328 t='$(program_transform_name)'; echo ranlib | sed -e 's/x/x/' $$t ; \
329 fi; \
330 fi`
331
332NM_FOR_TARGET = ` \
333 if [ -f $$r/binutils/nm-new ] ; then \
334 echo $$r/binutils/nm-new ; \
dc70af01
AO
335 elif [ -f $$r/gcc/xgcc ]; then \
336 $(CC_FOR_TARGET) -print-prog-name=nm ; \
252b5132 337 else \
3f152009 338 if [ '$(host_canonical)' = '$(target_canonical)' ] ; then \
252b5132
RH
339 echo $(NM); \
340 else \
341 t='$(program_transform_name)'; echo nm | sed -e 's/x/x/' $$t ; \
342 fi; \
343 fi`
344
345# The first rule in the file had better be this one. Don't put any above it.
346# This lives here to allow makefile fragments to contain dependencies.
347all: all.normal
348.PHONY: all
349
350# These can be overridden by config/mt-*.
351# The _TARGET_ is because they're specified in mt-foo.
352# The _HOST_ is because they're programs that run on the host.
353EXTRA_TARGET_HOST_ALL_MODULES =
354EXTRA_TARGET_HOST_INSTALL_MODULES =
355EXTRA_TARGET_HOST_CHECK_MODULES =
356
357#### host and target specific makefile fragments come in here.
358###
359
360# Flags to pass down to all sub-makes.
361# Please keep these in alphabetical order.
362BASE_FLAGS_TO_PASS = \
363 "AR_FLAGS=$(AR_FLAGS)" \
364 "AR_FOR_TARGET=$(AR_FOR_TARGET)" \
365 "AS_FOR_TARGET=$(AS_FOR_TARGET)" \
366 "BISON=$(BISON)" \
367 "CC_FOR_BUILD=$(CC_FOR_BUILD)" \
368 "CC_FOR_TARGET=$(CC_FOR_TARGET)" \
369 "CFLAGS=$(CFLAGS)" \
370 "CFLAGS_FOR_TARGET=$(CFLAGS_FOR_TARGET)" \
75205f78 371 "GCJ_FOR_TARGET=$(GCJ_FOR_TARGET)" \
252b5132
RH
372 "CXX_FOR_BUILD=$(CXX_FOR_BUILD)" \
373 "CXXFLAGS=$(CXXFLAGS)" \
374 "CXXFLAGS_FOR_TARGET=$(CXXFLAGS_FOR_TARGET)" \
375 "CXX_FOR_TARGET=$(CXX_FOR_TARGET)" \
376 "DLLTOOL_FOR_TARGET=$(DLLTOOL_FOR_TARGET)" \
377 "INSTALL=$(INSTALL)" \
378 "INSTALL_DATA=$(INSTALL_DATA)" \
379 "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \
380 "INSTALL_SCRIPT=$(INSTALL_SCRIPT)" \
381 "LDFLAGS=$(LDFLAGS)" \
382 "LEX=$(LEX)" \
383 "LD_FOR_TARGET=$(LD_FOR_TARGET)" \
384 "LIBCFLAGS=$(LIBCFLAGS)" \
385 "LIBCFLAGS_FOR_TARGET=$(LIBCFLAGS_FOR_TARGET)" \
386 "LIBCXXFLAGS=$(LIBCXXFLAGS)" \
387 "LIBCXXFLAGS_FOR_TARGET=$(LIBCXXFLAGS_FOR_TARGET)" \
388 "M4=$(M4)" \
389 "MAKE=$(MAKE)" \
390 "MAKEINFO=$(MAKEINFO) $(MAKEINFOFLAGS)" \
391 "NM_FOR_TARGET=$(NM_FOR_TARGET)" \
392 "RANLIB_FOR_TARGET=$(RANLIB_FOR_TARGET)" \
393 "RPATH_ENVVAR=$(RPATH_ENVVAR)" \
394 "SHELL=$(SHELL)" \
395 "EXPECT=$(EXPECT)" \
396 "RUNTEST=$(RUNTEST)" \
397 "RUNTESTFLAGS=$(RUNTESTFLAGS)" \
398 "TARGET_SUBDIR=$(TARGET_SUBDIR)" \
399 "WINDRES_FOR_TARGET=$(WINDRES_FOR_TARGET)" \
400 "YACC=$(YACC)" \
401 "bindir=$(bindir)" \
402 "datadir=$(datadir)" \
403 "exec_prefix=$(exec_prefix)" \
404 "includedir=$(includedir)" \
405 "infodir=$(infodir)" \
406 "libdir=$(libdir)" \
407 "libexecdir=$(libexecdir)" \
408 "lispdir=$(lispdir)" \
75205f78
DD
409 "libstdcxx_incdir=$(libstdcxx_incdir)" \
410 "libsubdir=$(libsubdir)" \
252b5132
RH
411 "localstatedir=$(localstatedir)" \
412 "mandir=$(mandir)" \
413 "oldincludedir=$(oldincludedir)" \
414 "prefix=$(prefix)" \
415 "sbindir=$(sbindir)" \
416 "sharedstatedir=$(sharedstatedir)" \
417 "sysconfdir=$(sysconfdir)" \
418 "tooldir=$(tooldir)" \
ba73c63f 419 "build_tooldir=$(build_tooldir)" \
252b5132
RH
420 "gxx_include_dir=$(gxx_include_dir)" \
421 "gcc_version=$(gcc_version)" \
422 "gcc_version_trigger=$(gcc_version_trigger)" \
75205f78 423 "target_alias=$(target_alias)"
252b5132 424
dec0cb0c
AO
425# For any flags above that may contain shell code that varies from one
426# target library to another. When doing recursive invocations of the
427# top-level Makefile, we don't want the outer make to evaluate them,
428# so we pass these variables down unchanged. They must not contain
429# single nor double quotes.
430RECURSE_FLAGS = \
431 CXX_FOR_TARGET='$(CXX_FOR_TARGET_FOR_RECURSIVE_MAKE)'
432
252b5132
RH
433# Flags to pass down to most sub-makes, in which we're building with
434# the host environment.
435# If any variables are added here, they must be added to do-*, below.
436EXTRA_HOST_FLAGS = \
437 'AR=$(AR)' \
438 'AS=$(AS)' \
439 'CC=$(CC)' \
440 'CXX=$(CXX)' \
441 'DLLTOOL=$(DLLTOOL)' \
442 'LD=$(LD)' \
443 'NM=$(NM)' \
75205f78 444 "`echo 'RANLIB=$(RANLIB)' | sed -e s/.*=$$/XFOO=/`" \
252b5132
RH
445 'WINDRES=$(WINDRES)'
446
447FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_HOST_FLAGS)
448
449# Flags that are concerned with the location of the X11 include files
450# and library files
451#
452# NOTE: until the top-level is getting the values via autoconf, it only
453# causes problems to have this top-level Makefile overriding the autoconf-set
454# values in child directories. Only variables that don't conflict with
455# autoconf'ed ones should be passed by X11_FLAGS_TO_PASS for now.
456#
457X11_FLAGS_TO_PASS = \
458 'X11_EXTRA_CFLAGS=$(X11_EXTRA_CFLAGS)' \
459 'X11_EXTRA_LIBS=$(X11_EXTRA_LIBS)'
460
461# Flags to pass down to makes which are built with the target environment.
462# The double $ decreases the length of the command line; the variables
463# are set in BASE_FLAGS_TO_PASS, and the sub-make will expand them.
464# If any variables are added here, they must be added to do-*, below.
465EXTRA_TARGET_FLAGS = \
466 'AR=$$(AR_FOR_TARGET)' \
467 'AS=$$(AS_FOR_TARGET)' \
468 'CC=$$(CC_FOR_TARGET)' \
469 'CFLAGS=$$(CFLAGS_FOR_TARGET)' \
470 'CXX=$$(CXX_FOR_TARGET)' \
471 'CXXFLAGS=$$(CXXFLAGS_FOR_TARGET)' \
472 'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \
473 'LD=$$(LD_FOR_TARGET)' \
474 'LIBCFLAGS=$$(LIBCFLAGS_FOR_TARGET)' \
475 'LIBCXXFLAGS=$$(LIBCXXFLAGS_FOR_TARGET)' \
476 'NM=$$(NM_FOR_TARGET)' \
477 'RANLIB=$$(RANLIB_FOR_TARGET)' \
478 'WINDRES=$$(WINDRES_FOR_TARGET)'
479
480TARGET_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_TARGET_FLAGS)
481
482# Flags to pass down to gcc. gcc builds a library, libgcc.a, so it
483# unfortunately needs the native compiler and the target ar and
484# ranlib.
485# If any variables are added here, they must be added to do-*, below.
486# The HOST_* variables are a special case, which are used for the gcc
487# cross-building scheme.
488EXTRA_GCC_FLAGS = \
489 'AR=$(AR)' \
490 'AS=$(AS)' \
491 'CC=$(CC)' \
492 'CXX=$(CXX)' \
493 'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \
494 'HOST_CC=$(CC_FOR_BUILD)' \
27f15fdd
DD
495 'BUILD_PREFIX=$(BUILD_PREFIX)' \
496 'BUILD_PREFIX_1=$(BUILD_PREFIX_1)' \
252b5132 497 'NM=$(NM)' \
75205f78 498 "`echo 'RANLIB=$(RANLIB)' | sed -e s/.*=$$/XFOO=/`" \
252b5132
RH
499 'WINDRES=$$(WINDRES_FOR_TARGET)' \
500 "GCC_FOR_TARGET=$(GCC_FOR_TARGET)" \
75205f78 501 "CFLAGS_FOR_BUILD=$(CFLAGS_FOR_BUILD)" \
252b5132
RH
502 "`echo 'LANGUAGES=$(LANGUAGES)' | sed -e s/.*=$$/XFOO=/`" \
503 "`echo 'STMP_FIXPROTO=$(STMP_FIXPROTO)' | sed -e s/.*=$$/XFOO=/`" \
504 "`echo 'LIMITS_H_TEST=$(LIMITS_H_TEST)' | sed -e s/.*=$$/XFOO=/`" \
252b5132
RH
505 "`echo 'LIBGCC2_CFLAGS=$(LIBGCC2_CFLAGS)' | sed -e s/.*=$$/XFOO=/`" \
506 "`echo 'LIBGCC2_DEBUG_CFLAGS=$(LIBGCC2_DEBUG_CFLAGS)' | sed -e s/.*=$$/XFOO=/`" \
507 "`echo 'LIBGCC2_INCLUDES=$(LIBGCC2_INCLUDES)' | sed -e s/.*=$$/XFOO=/`" \
508 "`echo 'ENQUIRE=$(ENQUIRE)' | sed -e s/.*=$$/XFOO=/`" \
75205f78 509 "`echo 'STAGE1_CFLAGS=$(STAGE1_CFLAGS)' | sed -e s/.*=$$/XFOO=/`" \
252b5132
RH
510 "`echo 'BOOT_CFLAGS=$(BOOT_CFLAGS)' | sed -e s/.*=$$/XFOO=/`"
511
512GCC_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_GCC_FLAGS)
513
49b7683b
DD
514# This is a list of the targets for all of the modules which are compiled
515# using the build machine's native compiler. Configure edits the second
516# macro for build!=host builds.
517ALL_BUILD_MODULES_LIST = \
518 all-build-libiberty
519ALL_BUILD_MODULES =
520
521# This is a list of the configure targets for all of the modules which
522# are compiled using the native tools.
523CONFIGURE_BUILD_MODULES = \
524 configure-build-libiberty
525
252b5132
RH
526# This is a list of the targets for all of the modules which are compiled
527# using $(FLAGS_TO_PASS).
528ALL_MODULES = \
252b5132
RH
529 all-ash \
530 all-autoconf \
531 all-automake \
532 all-bash \
533 all-bfd \
405ea7a0 534 all-opcodes \
252b5132
RH
535 all-binutils \
536 all-bison \
537 all-byacc \
538 all-bzip2 \
252b5132
RH
539 all-db \
540 all-dejagnu \
541 all-diff \
542 all-dosutils \
543 all-etc \
75205f78 544 all-fastjar \
252b5132
RH
545 all-fileutils \
546 all-findutils \
547 all-find \
548 all-flex \
549 all-gas \
550 all-gawk \
551 all-gettext \
552 all-gnuserv \
553 all-gprof \
554 all-grep \
252b5132
RH
555 all-gzip \
556 all-hello \
557 all-indent \
252b5132 558 all-intl \
405ea7a0 559 all-tcl \
252b5132
RH
560 all-itcl \
561 all-ld \
562 all-libgui \
563 all-libiberty \
564 all-libtool \
565 all-m4 \
566 all-make \
567 all-mmalloc \
252b5132
RH
568 all-patch \
569 all-perl \
570 all-prms \
571 all-rcs \
572 all-readline \
573 all-release \
574 all-recode \
575 all-sed \
576 all-send-pr \
577 all-shellutils \
8817b92e 578 all-sid \
252b5132 579 all-sim \
ba73c63f 580 all-snavigator \
252b5132 581 all-tar \
252b5132
RH
582 all-texinfo \
583 all-textutils \
252b5132
RH
584 all-time \
585 all-uudecode \
586 all-wdiff \
587 all-zip \
5cec67bf 588 all-zlib \
252b5132
RH
589 $(EXTRA_TARGET_HOST_ALL_MODULES)
590
591# This is a list of the check targets for all of the modules which are
592# compiled using $(FLAGS_TO_PASS).
593#
594# The list is in two parts. The first lists those tools which
595# are tested as part of the host's native tool-chain, and not
596# tested in a cross configuration.
597NATIVE_CHECK_MODULES = \
598 check-bison \
599 check-byacc \
75205f78 600 check-fastjar \
252b5132
RH
601 check-flex \
602 check-zip
603
604CROSS_CHECK_MODULES = \
252b5132
RH
605 check-ash \
606 check-autoconf \
607 check-automake \
608 check-bash \
609 check-bfd \
405ea7a0 610 check-opcodes \
252b5132
RH
611 check-binutils \
612 check-bzip2 \
252b5132
RH
613 check-db \
614 check-dejagnu \
615 check-diff \
616 check-etc \
617 check-fileutils \
618 check-findutils \
619 check-find \
620 check-gas \
621 check-gawk \
622 check-gettext \
623 check-gnuserv \
624 check-gprof \
625 check-grep \
626 check-gzip \
627 check-hello \
628 check-indent \
252b5132 629 check-intl \
405ea7a0 630 check-tcl \
252b5132
RH
631 check-itcl \
632 check-ld \
633 check-libgui \
634 check-libiberty \
635 check-libtool \
636 check-m4 \
637 check-make \
252b5132
RH
638 check-patch \
639 check-perl \
640 check-prms \
641 check-rcs \
642 check-readline \
643 check-recode \
644 check-sed \
645 check-send-pr \
646 check-shellutils \
8817b92e 647 check-sid \
252b5132 648 check-sim \
405ea7a0 649 check-snavigator \
252b5132 650 check-tar \
252b5132
RH
651 check-texinfo \
652 check-textutils \
252b5132
RH
653 check-time \
654 check-uudecode \
655 check-wdiff \
656 $(EXTRA_TARGET_HOST_CHECK_MODULES)
657
658CHECK_MODULES=$(NATIVE_CHECK_MODULES) $(CROSS_CHECK_MODULES)
659
660# This is a list of the install targets for all of the modules which are
661# compiled using $(FLAGS_TO_PASS).
662# We put install-opcodes before install-binutils because the installed
663# binutils might be on PATH, and they might need the shared opcodes
664# library.
665# We put install-tcl before install-itcl because itcl wants to run a
666# program on installation which uses the Tcl libraries.
667INSTALL_MODULES = \
252b5132
RH
668 install-ash \
669 install-autoconf \
670 install-automake \
671 install-bash \
672 install-bfd \
252b5132
RH
673 install-opcodes \
674 install-binutils \
675 install-bison \
676 install-byacc \
405ea7a0 677 install-bzip2 \
252b5132
RH
678 install-db \
679 install-dejagnu \
680 install-diff \
681 install-dosutils \
682 install-etc \
75205f78 683 install-fastjar \
252b5132
RH
684 install-fileutils \
685 install-findutils \
686 install-find \
687 install-flex \
688 install-gas \
689 install-gawk \
690 install-gettext \
691 install-gnuserv \
692 install-gprof \
693 install-grep \
252b5132
RH
694 install-gzip \
695 install-hello \
696 install-indent \
252b5132 697 install-intl \
252b5132 698 install-tcl \
252b5132
RH
699 install-itcl \
700 install-ld \
701 install-libgui \
702 install-libiberty \
703 install-libtool \
704 install-m4 \
705 install-make \
706 install-mmalloc \
707 install-patch \
708 install-perl \
709 install-prms \
710 install-rcs \
711 install-readline \
712 install-recode \
713 install-sed \
714 install-send-pr \
715 install-shellutils \
8817b92e 716 install-sid \
252b5132 717 install-sim \
ba73c63f 718 install-snavigator \
252b5132 719 install-tar \
252b5132 720 install-textutils \
252b5132
RH
721 install-time \
722 install-uudecode \
723 install-wdiff \
724 install-zip \
725 $(EXTRA_TARGET_HOST_INSTALL_MODULES)
726
727# This is a list of the targets for all of the modules which are compiled
728# using $(X11_FLAGS_TO_PASS).
729ALL_X11_MODULES = \
252b5132
RH
730 all-gdb \
731 all-expect \
252b5132
RH
732 all-guile \
733 all-tclX \
734 all-tk \
252b5132
RH
735 all-tix
736
737# This is a list of the check targets for all of the modules which are
738# compiled using $(X11_FLAGS_TO_PASS).
739CHECK_X11_MODULES = \
252b5132
RH
740 check-gdb \
741 check-guile \
742 check-expect \
252b5132
RH
743 check-tclX \
744 check-tk \
745 check-tix
746
747# This is a list of the install targets for all the modules which are
748# compiled using $(X11_FLAGS_TO_PASS).
749INSTALL_X11_MODULES = \
252b5132
RH
750 install-gdb \
751 install-guile \
752 install-expect \
252b5132
RH
753 install-tclX \
754 install-tk \
252b5132
RH
755 install-tix
756
757# This is a list of the targets for all of the modules which are compiled
758# using $(TARGET_FLAGS_TO_PASS).
759ALL_TARGET_MODULES = \
ba73c63f 760 all-target-libstdc++-v3 \
252b5132 761 all-target-newlib \
ba73c63f 762 all-target-libf2c \
ba73c63f 763 all-target-libobjc \
252b5132
RH
764 all-target-libtermcap \
765 all-target-winsup \
766 all-target-libgloss \
767 all-target-libiberty \
768 all-target-gperf \
769 all-target-examples \
ba73c63f
JM
770 all-target-libffi \
771 all-target-libjava \
772 all-target-zlib \
773 all-target-boehm-gc \
907a7241 774 all-target-qthreads
252b5132
RH
775
776# This is a list of the configure targets for all of the modules which
777# are compiled using the target tools.
778CONFIGURE_TARGET_MODULES = \
ba73c63f 779 configure-target-libstdc++-v3 \
252b5132 780 configure-target-newlib \
ba73c63f 781 configure-target-libf2c \
ba73c63f 782 configure-target-libobjc \
252b5132
RH
783 configure-target-libtermcap \
784 configure-target-winsup \
785 configure-target-libgloss \
786 configure-target-libiberty \
787 configure-target-gperf \
788 configure-target-examples \
ba73c63f
JM
789 configure-target-libffi \
790 configure-target-libjava \
791 configure-target-zlib \
792 configure-target-boehm-gc \
907a7241 793 configure-target-qthreads
252b5132
RH
794
795# This is a list of the check targets for all of the modules which are
796# compiled using $(TARGET_FLAGS_TO_PASS).
797CHECK_TARGET_MODULES = \
ba73c63f 798 check-target-libstdc++-v3 \
252b5132 799 check-target-newlib \
ba73c63f 800 check-target-libf2c \
ba73c63f 801 check-target-libobjc \
252b5132
RH
802 check-target-winsup \
803 check-target-libiberty \
907a7241 804 check-target-gperf \
ba73c63f
JM
805 check-target-libffi \
806 check-target-libjava \
807 check-target-zlib \
808 check-target-boehm-gc \
907a7241 809 check-target-qthreads
252b5132
RH
810
811# This is a list of the install targets for all of the modules which are
812# compiled using $(TARGET_FLAGS_TO_PASS).
813INSTALL_TARGET_MODULES = \
ba73c63f 814 install-target-libstdc++-v3 \
252b5132 815 install-target-newlib \
ba73c63f 816 install-target-libf2c \
ba73c63f 817 install-target-libobjc \
252b5132
RH
818 install-target-libtermcap \
819 install-target-winsup \
820 install-target-libgloss \
821 install-target-libiberty \
907a7241 822 install-target-gperf \
ba73c63f
JM
823 install-target-libjava \
824 install-target-zlib \
825 install-target-boehm-gc \
907a7241 826 install-target-qthreads
252b5132
RH
827
828# This is a list of the targets for which we can do a clean-{target}.
829CLEAN_MODULES = \
252b5132
RH
830 clean-ash \
831 clean-autoconf \
832 clean-automake \
833 clean-bash \
834 clean-bfd \
405ea7a0 835 clean-opcodes \
252b5132
RH
836 clean-binutils \
837 clean-bison \
838 clean-byacc \
839 clean-bzip2 \
252b5132
RH
840 clean-db \
841 clean-dejagnu \
842 clean-diff \
843 clean-dosutils \
844 clean-etc \
75205f78 845 clean-fastjar \
252b5132
RH
846 clean-fileutils \
847 clean-findutils \
848 clean-find \
849 clean-flex \
850 clean-gas \
851 clean-gawk \
852 clean-gettext \
853 clean-gnuserv \
854 clean-gprof \
855 clean-grep \
252b5132
RH
856 clean-gzip \
857 clean-hello \
858 clean-indent \
252b5132 859 clean-intl \
405ea7a0 860 clean-tcl \
252b5132
RH
861 clean-itcl \
862 clean-ld \
863 clean-libgui \
864 clean-libiberty \
865 clean-libtool \
866 clean-m4 \
867 clean-make \
868 clean-mmalloc \
252b5132
RH
869 clean-patch \
870 clean-perl \
871 clean-prms \
872 clean-rcs \
873 clean-readline \
874 clean-release \
875 clean-recode \
876 clean-sed \
877 clean-send-pr \
878 clean-shellutils \
8817b92e 879 clean-sid \
252b5132 880 clean-sim \
ba73c63f 881 clean-snavigator \
252b5132 882 clean-tar \
252b5132
RH
883 clean-texinfo \
884 clean-textutils \
252b5132
RH
885 clean-time \
886 clean-uudecode \
887 clean-wdiff \
5cec67bf 888 clean-zip \
405ea7a0 889 clean-zlib
252b5132
RH
890
891# All of the target modules that can be cleaned
892CLEAN_TARGET_MODULES = \
ba73c63f 893 clean-target-libstdc++-v3 \
252b5132 894 clean-target-newlib \
ba73c63f 895 clean-target-libf2c \
ba73c63f 896 clean-target-libobjc \
252b5132
RH
897 clean-target-winsup \
898 clean-target-libgloss \
899 clean-target-libiberty \
900 clean-target-gperf \
901 clean-target-examples \
ba73c63f
JM
902 clean-target-libffi \
903 clean-target-libjava \
904 clean-target-zlib \
905 clean-target-boehm-gc \
907a7241 906 clean-target-qthreads
252b5132
RH
907
908# All of the x11 modules that can be cleaned
909CLEAN_X11_MODULES = \
252b5132
RH
910 clean-gdb \
911 clean-expect \
252b5132
RH
912 clean-guile \
913 clean-tclX \
914 clean-tk \
915 clean-tix
916
917# The target built for a native build.
918.PHONY: all.normal
919all.normal: \
49b7683b 920 $(ALL_BUILD_MODULES) \
252b5132
RH
921 $(ALL_MODULES) \
922 $(ALL_X11_MODULES) \
923 $(ALL_TARGET_MODULES) \
924 all-gcc
925
926# Do a target for all the subdirectories. A ``make do-X'' will do a
927# ``make X'' in all subdirectories (because, in general, there is a
928# dependency (below) of X upon do-X, a ``make X'' will also do this,
929# but it may do additional work as well).
930# This target ensures that $(BASE_FLAGS_TO_PASS) appears only once,
931# because it is so large that it can easily overflow the command line
932# length limit on some systems.
933DO_X = \
934 do-clean \
935 do-distclean \
936 do-dvi \
937 do-info \
938 do-install-info \
939 do-installcheck \
940 do-mostlyclean \
941 do-maintainer-clean \
942 do-TAGS
943.PHONY: $(DO_X)
944$(DO_X):
945 @target=`echo $@ | sed -e 's/^do-//'`; \
d5de0a84
NC
946 r=`${PWD}`; export r; \
947 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132
RH
948 $(SET_LIB_PATH) \
949 for i in $(SUBDIRS) -dummy-; do \
950 if [ -f ./$$i/Makefile ]; then \
951 case $$i in \
952 gcc) \
953 for flag in $(EXTRA_GCC_FLAGS); do \
3f152009 954 eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
252b5132
RH
955 done; \
956 ;; \
957 *) \
958 for flag in $(EXTRA_HOST_FLAGS); do \
3f152009 959 eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
252b5132
RH
960 done; \
961 ;; \
962 esac ; \
252b5132
RH
963 if (cd ./$$i; \
964 $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
965 "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
75205f78 966 "`echo \"RANLIB=$${RANLIB}\" | sed -e 's/.*=$$/XFOO=/'`" \
252b5132
RH
967 "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
968 $${target}); \
969 then true; else exit 1; fi; \
970 else true; fi; \
971 done
972 @target=`echo $@ | sed -e 's/^do-//'`; \
d5de0a84
NC
973 r=`${PWD}`; export r; \
974 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132
RH
975 $(SET_LIB_PATH) \
976 for i in $(TARGET_CONFIGDIRS) -dummy-; do \
977 if [ -f $(TARGET_SUBDIR)/$$i/Makefile ]; then \
978 for flag in $(EXTRA_TARGET_FLAGS); do \
3f152009 979 eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
252b5132 980 done; \
252b5132
RH
981 if (cd $(TARGET_SUBDIR)/$$i; \
982 $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
983 "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
75205f78 984 "`echo \"RANLIB=$${RANLIB}\" | sed -e 's/.*=$$/XFOO=/'`" \
252b5132
RH
985 "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
986 $${target}); \
987 then true; else exit 1; fi; \
988 else true; fi; \
989 done
990
991# Here are the targets which correspond to the do-X targets.
992
993.PHONY: info installcheck dvi install-info
994.PHONY: clean distclean mostlyclean maintainer-clean realclean
995.PHONY: local-clean local-distclean local-maintainer-clean
996info: do-info
997installcheck: do-installcheck
998dvi: do-dvi
999
1000# Make sure makeinfo is built before we do a `make info'.
1001do-info: all-texinfo
1002
1003install-info: do-install-info dir.info
d5de0a84 1004 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132
RH
1005 if [ -f dir.info ] ; then \
1006 $(INSTALL_DATA) dir.info $(infodir)/dir.info ; \
1007 else true ; fi
1008
1009local-clean:
1010 -rm -f *.a TEMP errs core *.o *~ \#* TAGS *.E *.log
1011
1012local-distclean:
1013 -rm -f Makefile config.status config.cache mh-frag mt-frag
1014 -if [ "$(TARGET_SUBDIR)" != "." ]; then \
1015 rm -rf $(TARGET_SUBDIR); \
1016 else true; fi
75205f78
DD
1017 -rm -f texinfo/po/Makefile texinfo/po/Makefile.in texinfo/info/Makefile
1018 -rm -f texinfo/doc/Makefile texinfo/po/POTFILES
1019 -rmdir texinfo/doc texinfo/info texinfo/intl texinfo/lib 2>/dev/null
1020 -rmdir texinfo/makeinfo texinfo/po texinfo/util 2>/dev/null
1021 -rmdir fastjar gcc libiberty texinfo zlib 2>/dev/null
252b5132
RH
1022
1023local-maintainer-clean:
1024 @echo "This command is intended for maintainers to use;"
1025 @echo "it deletes files that may require special tools to rebuild."
1026
1027clean: do-clean local-clean
1028mostlyclean: do-mostlyclean local-clean
1029distclean: do-distclean local-clean local-distclean
1030maintainer-clean: local-maintainer-clean do-maintainer-clean local-clean
1031maintainer-clean: local-distclean
1032realclean: maintainer-clean
1033
1034# This rule is used to clean specific modules.
1035.PHONY: $(CLEAN_MODULES) $(CLEAN_X11_MODULES) clean-gcc
1036$(CLEAN_MODULES) $(CLEAN_X11_MODULES) clean-gcc:
1037 @dir=`echo $@ | sed -e 's/clean-//'`; \
1038 if [ -f ./$${dir}/Makefile ] ; then \
d5de0a84
NC
1039 r=`${PWD}`; export r; \
1040 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132
RH
1041 $(SET_LIB_PATH) \
1042 (cd $${dir}; $(MAKE) $(FLAGS_TO_PASS) clean); \
1043 else \
1044 true; \
1045 fi
1046
1047.PHONY: $(CLEAN_TARGET_MODULES)
1048$(CLEAN_TARGET_MODULES):
1049 @dir=`echo $@ | sed -e 's/clean-target-//'`; \
1050 rm -f $(TARGET_SUBDIR)/$${dir}/multilib.out $(TARGET_SUBDIR)/$${dir}/tmpmulti.out; \
1051 if [ -f $(TARGET_SUBDIR)/$${dir}/Makefile ] ; then \
d5de0a84
NC
1052 r=`${PWD}`; export r; \
1053 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132
RH
1054 $(SET_LIB_PATH) \
1055 (cd $(TARGET_SUBDIR)/$${dir}; $(MAKE) $(TARGET_FLAGS_TO_PASS) clean); \
1056 else \
1057 true; \
1058 fi
1059
5cec67bf
AO
1060clean-target: $(CLEAN_TARGET_MODULES) clean-target-libgcc
1061clean-target-libgcc:
1062 test ! -d gcc/libgcc || \
1063 (cd gcc/libgcc && find . -type d -print) | \
1064 while read d; do rm -f gcc/$$d/libgcc.a || : ; done
1065 -rm -rf gcc/libgcc
252b5132
RH
1066
1067# Check target.
1068
80413487
RH
1069.PHONY: check do-check
1070check:
1071 $(MAKE) do-check NOTPARALLEL=parallel-ok
1072
1073do-check: $(CHECK_MODULES) \
252b5132
RH
1074 $(CHECK_TARGET_MODULES) \
1075 $(CHECK_X11_MODULES) \
1076 check-gcc
1077
1078# Automated reporting of test results.
1079
1080warning.log: build.log
1081 $(srcdir)/contrib/warn_summary build.log > $@
1082
1083mail-report.log:
1084 if test x'$(BOOT_CFLAGS)' != x''; then \
1085 BOOT_CFLAGS='$(BOOT_CFLAGS)'; export BOOT_CFLAGS; \
1086 fi; \
1087 $(srcdir)/contrib/test_summary -t >$@
1088 chmod +x $@
1089 echo If you really want to send e-mail, run ./$@ now
1090
1091mail-report-with-warnings.log: warning.log
1092 if test x'$(BOOT_CFLAGS)' != x''; then \
1093 BOOT_CFLAGS='$(BOOT_CFLAGS)'; export BOOT_CFLAGS; \
1094 fi; \
1095 $(srcdir)/contrib/test_summary -t -i warning.log >$@
1096 chmod +x $@
1097 echo If you really want to send e-mail, run ./$@ now
1098
1099# Installation targets.
1100
1101.PHONY: install install-cross uninstall source-vault binary-vault vault-install
1102install: $(INSTALL_TARGET)
1103install-cross: $(INSTALL_TARGET_CROSS)
1104
1105uninstall:
1106 @echo "the uninstall target is not supported in this tree"
1107
1108source-vault:
1109 $(MAKE) -f ./release/Build-A-Release \
1110 host=$(host_alias) source-vault
1111
1112binary-vault:
1113 $(MAKE) -f ./release/Build-A-Release \
1114 host=$(host_alias) target=$(target_alias)
1115
1116vault-install:
1117 @if [ -f ./release/vault-install ] ; then \
1118 ./release/vault-install $(host_alias) $(target_alias) ; \
1119 else \
1120 true ; \
1121 fi
1122
1123.PHONY: install.all
1124install.all: install-no-fixedincludes
1125 @if [ -f ./gcc/Makefile ] ; then \
d5de0a84 1126 r=`${PWD}` ; export r ; \
252b5132
RH
1127 $(SET_LIB_PATH) \
1128 (cd ./gcc; \
1129 $(MAKE) $(FLAGS_TO_PASS) install-headers) ; \
1130 else \
1131 true ; \
1132 fi
1133
252b5132
RH
1134# install-no-fixedincludes is used because Cygnus can not distribute
1135# the fixed header files.
1136.PHONY: install-no-fixedincludes
1137install-no-fixedincludes: \
1138 installdirs \
1139 $(INSTALL_MODULES) \
1140 $(INSTALL_TARGET_MODULES) \
1141 $(INSTALL_X11_MODULES) \
1142 gcc-no-fixedincludes
1143
1144# Install the gcc headers files, but not the fixed include files,
1145# which Cygnus is not allowed to distribute. This rule is very
1146# dependent on the workings of the gcc Makefile.in.
1147.PHONY: gcc-no-fixedincludes
1148gcc-no-fixedincludes:
1149 @if [ -f ./gcc/Makefile ]; then \
1150 rm -rf gcc/tmp-include; \
1151 mv gcc/include gcc/tmp-include 2>/dev/null; \
1152 mkdir gcc/include; \
1153 cp $(srcdir)/gcc/gsyslimits.h gcc/include/syslimits.h; \
1154 touch gcc/stmp-fixinc gcc/include/fixed; \
1155 rm -f gcc/stmp-headers gcc/stmp-int-hdrs; \
d5de0a84
NC
1156 r=`${PWD}`; export r; \
1157 s=`cd $(srcdir); ${PWD}` ; export s; \
252b5132
RH
1158 $(SET_LIB_PATH) \
1159 (cd ./gcc; \
1160 $(MAKE) $(GCC_FLAGS_TO_PASS) install); \
1161 rm -rf gcc/include; \
1162 mv gcc/tmp-include gcc/include 2>/dev/null; \
1163 else true; fi
1164
49b7683b
DD
1165# This rule is used to build the modules which are built with the
1166# build machine's native compiler.
1167.PHONY: $(ALL_BUILD_MODULES)
1168$(ALL_BUILD_MODULES):
1169 dir=`echo $@ | sed -e 's/all-build-//'`; \
1170 if [ -f ./$${dir}/Makefile ] ; then \
d5de0a84
NC
1171 r=`${PWD}`; export r; \
1172 s=`cd $(srcdir); ${PWD}`; export s; \
49b7683b
DD
1173 (cd $(BUILD_SUBDIR)/$${dir} && $(MAKE) all); \
1174 else \
1175 true; \
1176 fi
1177
1178# This rule is used to configure the modules which are built with the
1179# native tools.
1180.PHONY: $(CONFIGURE_BUILD_MODULES)
1181$(CONFIGURE_BUILD_MODULES):
1182 @dir=`echo $@ | sed -e 's/configure-build-//'`; \
1183 if [ ! -d $(BUILD_SUBDIR) ]; then \
1184 true; \
1185 elif [ -f $(BUILD_SUBDIR)/$${dir}/Makefile ] ; then \
1186 true; \
1187 elif echo " $(BUILD_CONFIGDIRS) " | grep " $${dir} " >/dev/null 2>&1; then \
1188 if [ -d $(srcdir)/$${dir} ]; then \
1189 [ -d $(BUILD_SUBDIR)/$${dir} ] || mkdir $(BUILD_SUBDIR)/$${dir};\
d5de0a84
NC
1190 r=`${PWD}`; export r; \
1191 s=`cd $(srcdir); ${PWD}`; export s; \
49b7683b
DD
1192 AR="$(AR_FOR_BUILD)"; export AR; \
1193 AS="$(AS_FOR_BUILD)"; export AS; \
1194 CC="$(CC_FOR_BUILD)"; export CC; \
1195 CFLAGS="$(CFLAGS_FOR_BUILD)"; export CFLAGS; \
1196 CXX="$(CXX_FOR_BUILD)"; export CXX; \
1197 CXXFLAGS="$(CXXFLAGS_FOR_BUILD)"; export CXXFLAGS; \
1198 GCJ="$(GCJ_FOR_BUILD)"; export GCJ; \
1199 DLLTOOL="$(DLLTOOL_FOR_BUILD)"; export DLLTOOL; \
1200 LD="$(LD_FOR_BUILD)"; export LD; \
1201 LDFLAGS="$(LDFLAGS_FOR_BUILD)"; export LDFLAGS; \
1202 NM="$(NM_FOR_BUILD)"; export NM; \
1203 RANLIB="$(RANLIB_FOR_BUILD)"; export RANLIB; \
1204 WINDRES="$(WINDRES_FOR_BUILD)"; export WINDRES; \
1205 echo Configuring in $(BUILD_SUBDIR)/$${dir}; \
1206 cd "$(BUILD_SUBDIR)/$${dir}" || exit 1; \
1207 case $(srcdir) in \
1208 /* | [A-Za-z]:[\\/]*) \
1209 topdir=$(srcdir) ;; \
1210 *) \
1211 case "$(BUILD_SUBDIR)" in \
1212 .) topdir="../$(srcdir)" ;; \
1213 *) topdir="../../$(srcdir)" ;; \
1214 esac ;; \
1215 esac; \
1216 if [ "$(srcdir)" = "." ] ; then \
1217 if [ "$(BUILD_SUBDIR)" != "." ] ; then \
1218 if $(SHELL) $$s/symlink-tree $${topdir}/$${dir} "no-such-file" ; then \
1219 if [ -f Makefile ]; then \
1220 if $(MAKE) distclean; then \
1221 true; \
1222 else \
1223 exit 1; \
1224 fi; \
1225 else \
1226 true; \
1227 fi; \
1228 else \
1229 exit 1; \
1230 fi; \
1231 else \
1232 true; \
1233 fi; \
1234 srcdiroption="--srcdir=."; \
1235 libsrcdir="."; \
1236 else \
1237 srcdiroption="--srcdir=$${topdir}/$${dir}"; \
1238 libsrcdir="$$s/$${dir}"; \
1239 fi; \
1240 if [ -f $${libsrcdir}/configure ] ; then \
1241 rm -f no-such-file skip-this-dir; \
1242 CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
1243 $(BUILD_CONFIGARGS) $${srcdiroption} \
1244 --with-build-subdir="$(BUILD_SUBDIR)"; \
1245 else \
1246 rm -f no-such-file skip-this-dir; \
1247 CONFIG_SITE=no-such-file $(SHELL) $$s/configure \
1248 $(BUILD_CONFIGARGS) $${srcdiroption} \
1249 --with-build-subdir="$(BUILD_SUBDIR)"; \
1250 fi || exit 1; \
1251 if [ -f skip-this-dir ] ; then \
1252 sh skip-this-dir; \
1253 rm -f skip-this-dir; \
1254 cd ..; rmdir $${dir} || true; \
1255 else \
1256 true; \
1257 fi; \
1258 else \
1259 true; \
1260 fi; \
1261 else \
1262 true; \
1263 fi
1264
252b5132
RH
1265# This rule is used to build the modules which use FLAGS_TO_PASS. To
1266# build a target all-X means to cd to X and make all.
1267#
1268# all-gui, and all-libproc are handled specially because
1269# they are still experimental, and if they fail to build, that
1270# shouldn't stop "make all".
1271.PHONY: $(ALL_MODULES) all-gui all-libproc
1272$(ALL_MODULES) all-gui all-libproc:
1273 @dir=`echo $@ | sed -e 's/all-//'`; \
1274 if [ -f ./$${dir}/Makefile ] ; then \
d5de0a84
NC
1275 r=`${PWD}`; export r; \
1276 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132
RH
1277 $(SET_LIB_PATH) \
1278 (cd $${dir}; $(MAKE) $(FLAGS_TO_PASS) all); \
1279 else \
1280 true; \
1281 fi
1282
1283# These rules are used to check the modules which use FLAGS_TO_PASS.
1284# To build a target check-X means to cd to X and make check. Some
1285# modules are only tested in a native toolchain.
1286
1287.PHONY: $(CHECK_MODULES) $(NATIVE_CHECK_MODULES) $(CROSS_CHECK_MODULES)
1288$(NATIVE_CHECK_MODULES):
3f152009 1289 @if [ '$(host_canonical)' = '$(target_canonical)' ] ; then \
252b5132
RH
1290 dir=`echo $@ | sed -e 's/check-//'`; \
1291 if [ -f ./$${dir}/Makefile ] ; then \
d5de0a84
NC
1292 r=`${PWD}`; export r; \
1293 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132
RH
1294 $(SET_LIB_PATH) \
1295 (cd $${dir}; $(MAKE) $(FLAGS_TO_PASS) check); \
1296 else \
1297 true; \
1298 fi; \
1299 fi
1300
1301$(CROSS_CHECK_MODULES):
1302 @dir=`echo $@ | sed -e 's/check-//'`; \
1303 if [ -f ./$${dir}/Makefile ] ; then \
d5de0a84
NC
1304 r=`${PWD}`; export r; \
1305 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132
RH
1306 $(SET_LIB_PATH) \
1307 (cd $${dir}; $(MAKE) $(FLAGS_TO_PASS) check); \
1308 else \
1309 true; \
1310 fi
1311
1312# This rule is used to install the modules which use FLAGS_TO_PASS.
1313# To build a target install-X means to cd to X and make install.
1314.PHONY: $(INSTALL_MODULES)
1315$(INSTALL_MODULES): installdirs
1316 @dir=`echo $@ | sed -e 's/install-//'`; \
1317 if [ -f ./$${dir}/Makefile ] ; then \
d5de0a84
NC
1318 r=`${PWD}`; export r; \
1319 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132
RH
1320 $(SET_LIB_PATH) \
1321 (cd $${dir}; $(MAKE) $(FLAGS_TO_PASS) install); \
1322 else \
1323 true; \
1324 fi
1325
1326# This rule is used to configure the modules which are built with the
1327# target tools.
1328.PHONY: $(CONFIGURE_TARGET_MODULES)
1329$(CONFIGURE_TARGET_MODULES):
1330 @dir=`echo $@ | sed -e 's/configure-target-//'`; \
1331 if [ -d $(TARGET_SUBDIR)/$${dir} ]; then \
d5de0a84 1332 r=`${PWD}`; export r; \
252b5132
RH
1333 $(CC_FOR_TARGET) --print-multi-lib > $(TARGET_SUBDIR)/$${dir}/tmpmulti.out 2> /dev/null; \
1334 if [ -s $(TARGET_SUBDIR)/$${dir}/tmpmulti.out ]; then \
1335 if [ -f $(TARGET_SUBDIR)/$${dir}/multilib.out ]; then \
1336 if cmp $(TARGET_SUBDIR)/$${dir}/multilib.out $(TARGET_SUBDIR)/$${dir}/tmpmulti.out > /dev/null; then \
1337 rm -f $(TARGET_SUBDIR)/$${dir}/tmpmulti.out; \
1338 else \
1339 echo "Multilibs changed for $${dir}, reconfiguring"; \
1340 rm -f $(TARGET_SUBDIR)/$${dir}/multilib.out $(TARGET_SUBDIR)/$${dir}/Makefile; \
1341 mv $(TARGET_SUBDIR)/$${dir}/tmpmulti.out $(TARGET_SUBDIR)/$${dir}/multilib.out; \
1342 fi; \
1343 else \
1344 mv $(TARGET_SUBDIR)/$${dir}/tmpmulti.out $(TARGET_SUBDIR)/$${dir}/multilib.out; \
1345 fi; \
1346 fi; \
1347 fi; exit 0 # break command into two pieces
1348 @dir=`echo $@ | sed -e 's/configure-target-//'`; \
1349 if [ ! -d $(TARGET_SUBDIR) ]; then \
1350 true; \
1351 elif [ -f $(TARGET_SUBDIR)/$${dir}/Makefile ] ; then \
1352 true; \
1353 elif echo " $(TARGET_CONFIGDIRS) " | grep " $${dir} " >/dev/null 2>&1; then \
1354 if [ -d $(srcdir)/$${dir} ]; then \
1355 [ -d $(TARGET_SUBDIR)/$${dir} ] || mkdir $(TARGET_SUBDIR)/$${dir};\
d5de0a84
NC
1356 r=`${PWD}`; export r; \
1357 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132
RH
1358 $(SET_LIB_PATH) \
1359 AR="$(AR_FOR_TARGET)"; export AR; \
1360 AS="$(AS_FOR_TARGET)"; export AS; \
1361 CC="$(CC_FOR_TARGET)"; export CC; \
1362 CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
1363 CXX="$(CXX_FOR_TARGET)"; export CXX; \
1364 CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
75205f78 1365 GCJ="$(GCJ_FOR_TARGET)"; export GCJ; \
252b5132
RH
1366 DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
1367 LD="$(LD_FOR_TARGET)"; export LD; \
1368 LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
1369 NM="$(NM_FOR_TARGET)"; export NM; \
1370 RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
1371 WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES; \
1372 echo Configuring in $(TARGET_SUBDIR)/$${dir}; \
75205f78 1373 cd "$(TARGET_SUBDIR)/$${dir}" || exit 1; \
252b5132 1374 case $(srcdir) in \
75205f78 1375 /* | [A-Za-z]:[\\/]*) \
252b5132
RH
1376 topdir=$(srcdir) ;; \
1377 *) \
1378 case "$(TARGET_SUBDIR)" in \
1379 .) topdir="../$(srcdir)" ;; \
1380 *) topdir="../../$(srcdir)" ;; \
1381 esac ;; \
1382 esac; \
1383 if [ "$(srcdir)" = "." ] ; then \
1384 if [ "$(TARGET_SUBDIR)" != "." ] ; then \
1385 if $(SHELL) $$s/symlink-tree $${topdir}/$${dir} "no-such-file" ; then \
1386 if [ -f Makefile ]; then \
1387 if $(MAKE) distclean; then \
1388 true; \
1389 else \
1390 exit 1; \
1391 fi; \
1392 else \
1393 true; \
1394 fi; \
1395 else \
1396 exit 1; \
1397 fi; \
1398 else \
1399 true; \
1400 fi; \
1401 srcdiroption="--srcdir=."; \
1402 libsrcdir="."; \
1403 else \
1404 srcdiroption="--srcdir=$${topdir}/$${dir}"; \
1405 libsrcdir="$$s/$${dir}"; \
1406 fi; \
1407 if [ -f $${libsrcdir}/configure ] ; then \
1408 rm -f no-such-file skip-this-dir; \
1409 CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
49b7683b 1410 $(TARGET_CONFIGARGS) $${srcdiroption} \
252b5132
RH
1411 --with-target-subdir="$(TARGET_SUBDIR)"; \
1412 else \
1413 rm -f no-such-file skip-this-dir; \
1414 CONFIG_SITE=no-such-file $(SHELL) $$s/configure \
49b7683b 1415 $(TARGET_CONFIGARGS) $${srcdiroption} \
252b5132 1416 --with-target-subdir="$(TARGET_SUBDIR)"; \
75205f78 1417 fi || exit 1; \
252b5132
RH
1418 if [ -f skip-this-dir ] ; then \
1419 sh skip-this-dir; \
1420 rm -f skip-this-dir; \
1421 cd ..; rmdir $${dir} || true; \
1422 else \
1423 true; \
1424 fi; \
1425 else \
1426 true; \
1427 fi; \
1428 else \
1429 true; \
1430 fi
1431
1432# This rule is used to build the modules which use TARGET_FLAGS_TO_PASS.
1433# To build a target all-X means to cd to X and make all.
1434.PHONY: $(ALL_TARGET_MODULES)
1435$(ALL_TARGET_MODULES):
1436 @dir=`echo $@ | sed -e 's/all-target-//'`; \
1437 if [ -f $(TARGET_SUBDIR)/$${dir}/Makefile ] ; then \
d5de0a84
NC
1438 r=`${PWD}`; export r; \
1439 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132 1440 $(SET_LIB_PATH) \
dec0cb0c
AO
1441 (cd $(TARGET_SUBDIR)/$${dir}; \
1442 $(MAKE) $(TARGET_FLAGS_TO_PASS) all); \
252b5132
RH
1443 else \
1444 true; \
1445 fi
1446
1447# This rule is used to check the modules which use TARGET_FLAGS_TO_PASS.
1448# To build a target install-X means to cd to X and make install.
1449.PHONY: $(CHECK_TARGET_MODULES)
1450$(CHECK_TARGET_MODULES):
1451 @dir=`echo $@ | sed -e 's/check-target-//'`; \
1452 if [ -f $(TARGET_SUBDIR)/$${dir}/Makefile ] ; then \
d5de0a84
NC
1453 r=`${PWD}`; export r; \
1454 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132 1455 $(SET_LIB_PATH) \
dec0cb0c
AO
1456 (cd $(TARGET_SUBDIR)/$${dir}; \
1457 $(MAKE) $(TARGET_FLAGS_TO_PASS) check);\
252b5132
RH
1458 else \
1459 true; \
1460 fi
1461
1462# This rule is used to install the modules which use
1463# TARGET_FLAGS_TO_PASS. To build a target install-X means to cd to X
1464# and make install.
1465.PHONY: $(INSTALL_TARGET_MODULES)
1466$(INSTALL_TARGET_MODULES): installdirs
1467 @dir=`echo $@ | sed -e 's/install-target-//'`; \
1468 if [ -f $(TARGET_SUBDIR)/$${dir}/Makefile ] ; then \
d5de0a84
NC
1469 r=`${PWD}`; export r; \
1470 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132
RH
1471 $(SET_LIB_PATH) \
1472 (cd $(TARGET_SUBDIR)/$${dir}; \
1473 $(MAKE) $(TARGET_FLAGS_TO_PASS) install); \
1474 else \
1475 true; \
1476 fi
1477
1478# This rule is used to build the modules which use X11_FLAGS_TO_PASS.
1479# To build a target all-X means to cd to X and make all.
1480.PHONY: $(ALL_X11_MODULES)
1481$(ALL_X11_MODULES):
1482 @dir=`echo $@ | sed -e 's/all-//'`; \
1483 if [ -f ./$${dir}/Makefile ] ; then \
d5de0a84
NC
1484 r=`${PWD}`; export r; \
1485 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132
RH
1486 $(SET_LIB_PATH) \
1487 (cd $${dir}; \
1488 $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) all); \
1489 else \
1490 true; \
1491 fi
1492
1493# This rule is used to check the modules which use X11_FLAGS_TO_PASS.
1494# To build a target check-X means to cd to X and make all.
1495.PHONY: $(CHECK_X11_MODULES)
1496$(CHECK_X11_MODULES):
1497 @dir=`echo $@ | sed -e 's/check-//'`; \
1498 if [ -f ./$${dir}/Makefile ] ; then \
d5de0a84
NC
1499 r=`${PWD}`; export r; \
1500 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132
RH
1501 $(SET_LIB_PATH) \
1502 (cd $${dir}; \
1503 $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) check); \
1504 else \
1505 true; \
1506 fi
1507
1508# This rule is used to install the modules which use X11_FLAGS_TO_PASS.
1509# To build a target install-X means to cd to X and make install.
1510.PHONY: $(INSTALL_X11_MODULES)
1511$(INSTALL_X11_MODULES): installdirs
1512 @dir=`echo $@ | sed -e 's/install-//'`; \
1513 if [ -f ./$${dir}/Makefile ] ; then \
d5de0a84
NC
1514 r=`${PWD}`; export r; \
1515 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132
RH
1516 $(SET_LIB_PATH) \
1517 (cd $${dir}; \
1518 $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) install); \
1519 else \
1520 true; \
1521 fi
1522
1523# gcc is the only module which uses GCC_FLAGS_TO_PASS.
1524.PHONY: all-gcc
1525all-gcc:
1526 @if [ -f ./gcc/Makefile ] ; then \
d5de0a84
NC
1527 r=`${PWD}`; export r; \
1528 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132
RH
1529 $(SET_LIB_PATH) \
1530 (cd gcc; $(MAKE) $(GCC_FLAGS_TO_PASS) all); \
1531 else \
1532 true; \
1533 fi
1534
1535# Building GCC uses some tools for rebuilding "source" files
1536# like texinfo, bison/byacc, etc. So we must depend on those.
1537#
1538# While building GCC, it may be necessary to run various target
1539# programs like the assembler, linker, etc. So we depend on
1540# those too.
1541#
1542# In theory, on an SMP all those dependencies can be resolved
1543# in parallel.
1544#
1545.PHONY: bootstrap bootstrap-lean bootstrap2 bootstrap2-lean bootstrap3 bootstrap3-lean bootstrap4 bootstrap4-lean
2809b4b9 1546bootstrap bootstrap-lean bootstrap2 bootstrap2-lean bootstrap3 bootstrap3-lean bootstrap4 bootstrap4-lean: all-bootstrap
d5de0a84
NC
1547 @r=`${PWD}`; export r; \
1548 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132
RH
1549 $(SET_LIB_PATH) \
1550 echo "Bootstrapping the compiler"; \
5cec67bf 1551 cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) $@
d5de0a84
NC
1552 @r=`${PWD}`; export r; \
1553 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132
RH
1554 case "$@" in \
1555 *bootstrap4-lean ) \
1556 msg="Comparing stage3 and stage4 of the compiler"; \
1557 compare=compare3-lean ;; \
1558 *bootstrap4 ) msg="Comparing stage3 and stage4 of the compiler"; \
1559 compare=compare3 ;; \
1560 *-lean ) msg="Comparing stage2 and stage3 of the compiler"; \
1561 compare=compare-lean ;; \
1562 * ) msg="Comparing stage2 and stage3 of the compiler"; \
1563 compare=compare ;; \
1564 esac; \
1565 $(SET_LIB_PATH) \
1566 echo "$$msg"; \
5cec67bf 1567 cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) $$compare
d5de0a84
NC
1568 @r=`${PWD}`; export r; \
1569 s=`cd $(srcdir); ${PWD}` ; export s; \
252b5132
RH
1570 $(SET_LIB_PATH) \
1571 echo "Building runtime libraries"; \
dec0cb0c 1572 $(MAKE) $(BASE_FLAGS_TO_PASS) $(RECURSE_FLAGS) all
252b5132
RH
1573
1574.PHONY: cross
1575cross: all-texinfo all-bison all-byacc all-binutils all-gas all-ld
d5de0a84
NC
1576 @r=`${PWD}`; export r; \
1577 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132
RH
1578 $(SET_LIB_PATH) \
1579 echo "Building the C and C++ compiler"; \
5cec67bf 1580 cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) LANGUAGES="c c++"
d5de0a84
NC
1581 @r=`${PWD}`; export r; \
1582 s=`cd $(srcdir); ${PWD}` ; export s; \
252b5132
RH
1583 $(SET_LIB_PATH) \
1584 echo "Building runtime libraries"; \
dec0cb0c
AO
1585 $(MAKE) $(BASE_FLAGS_TO_PASS) $(RECURSE_FLAGS) \
1586 LANGUAGES="c c++" all
252b5132
RH
1587
1588.PHONY: check-gcc
1589check-gcc:
1590 @if [ -f ./gcc/Makefile ] ; then \
d5de0a84
NC
1591 r=`${PWD}`; export r; \
1592 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132
RH
1593 $(SET_LIB_PATH) \
1594 (cd gcc; $(MAKE) $(GCC_FLAGS_TO_PASS) check); \
1595 else \
1596 true; \
1597 fi
1598
75205f78
DD
1599.PHONY: check-c++
1600check-c++:
1601 @if [ -f ./gcc/Makefile ] ; then \
d5de0a84
NC
1602 r=`${PWD}`; export r; \
1603 s=`cd $(srcdir); ${PWD}`; export s; \
75205f78
DD
1604 $(SET_LIB_PATH) \
1605 (cd gcc; $(MAKE) $(GCC_FLAGS_TO_PASS) check-c++); \
1606 $(MAKE) check-target-libstdc++-v3; \
1607 else \
1608 true; \
1609 fi
1610
252b5132
RH
1611.PHONY: install-gcc
1612install-gcc:
1613 @if [ -f ./gcc/Makefile ] ; then \
d5de0a84
NC
1614 r=`${PWD}`; export r; \
1615 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132
RH
1616 $(SET_LIB_PATH) \
1617 (cd gcc; $(MAKE) $(GCC_FLAGS_TO_PASS) install); \
1618 else \
1619 true; \
1620 fi
1621
1622.PHONY: install-gcc-cross
1623install-gcc-cross:
1624 @if [ -f ./gcc/Makefile ] ; then \
d5de0a84
NC
1625 r=`${PWD}`; export r; \
1626 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132
RH
1627 $(SET_LIB_PATH) \
1628 (cd gcc; $(MAKE) $(GCC_FLAGS_TO_PASS) LANGUAGES="c c++" install); \
1629 else \
1630 true; \
1631 fi
1632# EXPERIMENTAL STUFF
1633# This rule is used to install the modules which use FLAGS_TO_PASS.
1634# To build a target install-X means to cd to X and make install.
1635.PHONY: install-dosrel
1636install-dosrel: installdirs info
1637 @dir=`echo $@ | sed -e 's/install-//'`; \
1638 if [ -f ./$${dir}/Makefile ] ; then \
d5de0a84
NC
1639 r=`${PWD}`; export r; \
1640 s=`cd $(srcdir); ${PWD}`; export s; \
252b5132
RH
1641 $(SET_LIB_PATH) \
1642 (cd $${dir}; $(MAKE) $(FLAGS_TO_PASS) install); \
1643 else \
1644 true; \
1645 fi
1646
1647install-dosrel-fake:
1648
c559bb17
AO
1649ALL_GCC = all-gcc
1650ALL_GCC_C = $(ALL_GCC) all-target-newlib all-target-libgloss
75205f78 1651ALL_GCC_CXX = $(ALL_GCC_C) all-target-libstdc++-v3
252b5132
RH
1652
1653# This is a list of inter-dependencies among modules.
252b5132
RH
1654all-ash:
1655all-autoconf: all-m4 all-texinfo
1656all-automake: all-m4 all-texinfo
1657all-bash:
1658all-bfd: all-libiberty all-intl
1659all-binutils: all-libiberty all-opcodes all-bfd all-flex all-bison all-byacc all-intl
227b9953 1660all-bison: all-texinfo
75205f78 1661configure-target-boehm-gc: $(ALL_GCC_C) configure-target-qthreads
252b5132
RH
1662all-byacc:
1663all-bzip2:
252b5132
RH
1664all-db:
1665all-dejagnu: all-tcl all-expect all-tk
1666all-diff: all-libiberty
252b5132 1667all-etc:
5cec67bf 1668configure-target-examples: $(ALL_GCC_C)
252b5132
RH
1669all-expect: all-tcl all-tk
1670all-fileutils: all-libiberty
1671all-findutils:
1672all-find:
1673all-flex: all-libiberty all-bison all-byacc
1674all-gas: all-libiberty all-opcodes all-bfd all-intl
252b5132 1675all-gawk:
5cec67bf 1676all-gcc: all-bison all-byacc all-binutils all-gas all-ld all-zlib
2809b4b9 1677all-bootstrap: all-libiberty all-texinfo all-bison all-byacc all-binutils all-gas all-ld all-zlib
252b5132
RH
1678GDB_TK = all-tk all-tcl all-itcl all-tix all-libgui
1679all-gdb: all-libiberty all-opcodes all-bfd all-mmalloc all-readline all-bison all-byacc all-sim $(gdbnlmrequirements) $(GDB_TK)
1680all-gettext:
1681all-gnuserv:
373688ac 1682configure-target-gperf: $(ALL_GCC_CXX)
907a7241 1683all-target-gperf: all-target-libiberty all-target-libstdc++-v3
252b5132 1684all-gprof: all-libiberty all-bfd all-opcodes all-intl
ba73c63f 1685all-grep: all-libiberty
e3b0c936 1686all-gui: all-gdb all-libproc
252b5132
RH
1687all-guile:
1688all-gzip: all-libiberty
1689all-hello: all-libiberty
1690all-indent:
252b5132 1691all-intl:
fd8958d5 1692all-itcl: all-tcl all-tk
252b5132 1693all-ld: all-libiberty all-bfd all-opcodes all-bison all-byacc all-flex all-intl
252b5132 1694configure-target-libgloss: $(ALL_GCC)
907a7241 1695all-target-libgloss: configure-target-newlib
fd8958d5 1696all-libgui: all-tcl all-tk all-itcl
252b5132 1697all-libiberty:
49b7683b
DD
1698
1699all-build-libiberty: configure-build-libiberty
1700
5cec67bf 1701configure-target-libffi: $(ALL_GCC_C)
75205f78 1702configure-target-libjava: $(ALL_GCC_C) configure-target-zlib configure-target-boehm-gc configure-target-qthreads configure-target-libffi
907a7241 1703all-target-libjava: all-fastjar all-target-zlib all-target-boehm-gc all-target-qthreads all-target-libffi
5cec67bf 1704configure-target-libstdc++-v3: $(ALL_GCC_C)
907a7241 1705all-target-libstdc++-v3: all-target-libiberty
252b5132 1706all-libtool:
5cec67bf 1707configure-target-libf2c: $(ALL_GCC_C)
907a7241 1708all-target-libf2c: all-target-libiberty
5cec67bf 1709configure-target-libobjc: $(ALL_GCC_C)
907a7241 1710all-target-libobjc: all-target-libiberty
b0dad762 1711all-m4: all-libiberty all-texinfo
252b5132
RH
1712all-make: all-libiberty
1713all-mmalloc:
1714configure-target-newlib: $(ALL_GCC)
5cec67bf 1715configure-target-libtermcap: $(ALL_GCC_C)
cdb9e2b8 1716all-opcodes: all-bfd all-libiberty
252b5132
RH
1717all-patch: all-libiberty
1718all-perl:
1719all-prms: all-libiberty
5cec67bf 1720configure-target-qthreads: $(ALL_GCC_C)
252b5132
RH
1721all-rcs:
1722all-readline:
1723all-recode: all-libiberty
1724all-sed: all-libiberty
1725all-send-pr: all-prms
1726all-shellutils:
8817b92e 1727all-sid: all-tcl all-tk
cdb9e2b8 1728all-sim: all-libiberty all-bfd all-opcodes all-readline
48d19748 1729all-snavigator: all-tcl all-tk all-itcl all-tix all-db all-grep all-libgui
252b5132
RH
1730all-tar: all-libiberty
1731all-tcl:
252b5132
RH
1732all-tclX: all-tcl all-tk
1733all-tk: all-tcl
252b5132
RH
1734all-texinfo: all-libiberty
1735all-textutils:
252b5132 1736all-time:
fd8958d5 1737all-tix: all-tcl all-tk
252b5132 1738all-wdiff:
5cec67bf 1739configure-target-winsup: $(ALL_GCC_C)
907a7241 1740all-target-winsup: all-target-libiberty all-target-libtermcap
252b5132
RH
1741all-uudecode: all-libiberty
1742all-zip:
51601921 1743all-zlib:
5cec67bf 1744configure-target-zlib: $(ALL_GCC_C)
75205f78
DD
1745all-fastjar: all-zlib all-libiberty
1746configure-target-fastjar: configure-target-zlib
1747all-target-fastjar: configure-target-fastjar all-target-zlib all-target-libiberty
5cec67bf 1748configure-target-libiberty: $(ALL_GCC_C)
252b5132
RH
1749all-target: $(ALL_TARGET_MODULES)
1750install-target: $(INSTALL_TARGET_MODULES)
afb8d725 1751install-gdb: install-tcl install-tk install-itcl install-tix install-libgui
8817b92e 1752install-sid: install-tcl install-tk
907a7241
NN
1753
1754# Dependencies of all-target-foo on configure-target-foo.
1755all-target-libstdc++-v3: configure-target-libstdc++-v3
1756all-target-newlib: configure-target-newlib
1757all-target-libf2c: configure-target-libf2c
1758all-target-libobjc: configure-target-libobjc
1759all-target-libtermcap: configure-target-libtermcap
1760all-target-winsup: configure-target-winsup
1761all-target-libgloss: configure-target-libgloss
1762all-target-libiberty: configure-target-libiberty
1763all-target-gperf: configure-target-gperf
1764all-target-examples: configure-target-examples
1765all-target-libffi: configure-target-libffi
1766all-target-libjava: configure-target-libjava
1767all-target-zlib: configure-target-zlib
1768all-target-boehm-gc: configure-target-boehm-gc
1769all-target-qthreads: configure-target-qthreads
1770
1771
252b5132
RH
1772### other supporting targets
1773
1774MAKEDIRS= \
d3d8a9ee
NC
1775 $(DESTDIR)$(prefix) \
1776 $(DESTDIR)$(exec_prefix)
252b5132
RH
1777.PHONY: installdirs
1778installdirs: mkinstalldirs
1779 $(SHELL) $(srcdir)/mkinstalldirs $(MAKEDIRS)
1780
1781dir.info: do-install-info
1782 if [ -f $(srcdir)/texinfo/gen-info-dir ] ; then \
1783 $(srcdir)/texinfo/gen-info-dir $(infodir) $(srcdir)/texinfo/dir.info-template > dir.info.new ; \
1784 mv -f dir.info.new dir.info ; \
1785 else true ; \
1786 fi
1787
1788dist:
1789 @echo "Building a full distribution of this tree isn't done"
1790 @echo "via 'make dist'. Check out the etc/ subdirectory"
1791
1792etags tags: TAGS
1793
1794# Right now this just builds TAGS in each subdirectory. emacs19 has the
1795# ability to use several tags files at once, so there is probably no need
1796# to combine them into one big TAGS file (like CVS 1.3 does). We could
1797# (if we felt like it) have this Makefile write a piece of elisp which
1798# the user could load to tell emacs19 where all the TAGS files we just
1799# built are.
1800TAGS: do-TAGS
1801
1802# with the gnu make, this is done automatically.
1803
1804Makefile: Makefile.in configure.in $(host_makefile_frag) $(target_makefile_frag) $(gcc_version_trigger)
1805 $(SHELL) ./config.status
1806
1807#
1808# Support for building net releases
1809
1810# Files in devo used in any net release.
1811# ChangeLog omitted because it may refer to files which are not in this
1812# distribution (perhaps it would be better to include it anyway).
1813DEVO_SUPPORT= README Makefile.in configure configure.in \
1814 config.guess config.if config.sub config move-if-change \
1815 mpw-README mpw-build.in mpw-config.in mpw-configure mpw-install \
1816 COPYING COPYING.LIB install-sh config-ml.in symlink-tree \
97f60b31 1817 mkinstalldirs ltconfig ltmain.sh missing ylwrap \
5cec67bf 1818 libtool.m4 gettext.m4 ltcf-c.sh ltcf-cxx.sh ltcf-gcj.sh
252b5132
RH
1819
1820# Files in devo/etc used in any net release.
1821# ChangeLog omitted because it may refer to files which are not in this
1822# distribution (perhaps it would be better to include it anyway).
1823ETC_SUPPORT= Makefile.in configure configure.in standards.texi \
ebf0fa2e
AJ
1824 make-stds.texi standards.info* configure.texi configure.info* \
1825 configbuild.* configdev.*
1826
252b5132
RH
1827
1828# When you use `make setup-dirs' or `make taz' you should always redefine
1829# this macro.
1830SUPPORT_FILES = list-of-support-files-for-tool-in-question
1831
b35ece4e
AC
1832# NOTE: No double quotes in the below. It is used within shell script
1833# as VER="$(VER)"
1107dce2
AM
1834VER = ` if grep 'AM_INIT_AUTOMAKE.*BFD_VERSION' $(TOOL)/configure.in >/dev/null 2>&1; then \
1835 sed < bfd/configure.in -n 's/AM_INIT_AUTOMAKE[^,]*, *\([^)]*\))/\1/p'; \
1836 elif grep AM_INIT_AUTOMAKE $(TOOL)/configure.in >/dev/null 2>&1; then \
b35ece4e 1837 sed < $(TOOL)/configure.in -n 's/AM_INIT_AUTOMAKE[^,]*, *\([^)]*\))/\1/p'; \
31a8b634
AC
1838 elif test -f $(TOOL)/version.in; then \
1839 head -1 $(TOOL)/version.in; \
1840 elif grep VERSION $(TOOL)/Makefile.in > /dev/null 2>&1; then \
b35ece4e 1841 sed < $(TOOL)/Makefile.in -n 's/^VERSION *= *//p'; \
31a8b634
AC
1842 else \
1843 echo VERSION; \
b35ece4e
AC
1844 fi`
1845PACKAGE = $(TOOL)
252b5132 1846
b35ece4e 1847.PHONY: taz
c1b640f7 1848taz: $(DEVO_SUPPORT) $(SUPPORT_FILES) texinfo/texinfo.tex
b35ece4e
AC
1849 $(MAKE) -f Makefile.in do-proto-toplev \
1850 TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
fd751128 1851 MD5PROG="$(MD5PROG)" \
b35ece4e
AC
1852 SUPPORT_FILES="$(SUPPORT_FILES)"
1853 $(MAKE) -f Makefile.in do-md5sum \
1854 TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
fd751128 1855 MD5PROG="$(MD5PROG)" \
b35ece4e 1856 SUPPORT_FILES="$(SUPPORT_FILES)"
bbf6e9e3
AC
1857 $(MAKE) -f Makefile.in do-tar \
1858 TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
1859 MD5PROG="$(MD5PROG)" \
1860 SUPPORT_FILES="$(SUPPORT_FILES)"
1861 $(MAKE) -f Makefile.in do-bz2 \
b35ece4e 1862 TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
fd751128 1863 MD5PROG="$(MD5PROG)" \
b35ece4e
AC
1864 SUPPORT_FILES="$(SUPPORT_FILES)"
1865
bbf6e9e3
AC
1866.PHONY: gdb-tar
1867gdb-tar: $(DEVO_SUPPORT) $(SUPPORT_FILES) texinfo/texinfo.tex
b5a23627
AC
1868 $(MAKE) -f Makefile.in do-proto-toplev \
1869 TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
1870 MD5PROG="$(MD5PROG)" \
1871 SUPPORT_FILES="$(SUPPORT_FILES)"
1872 $(MAKE) -f Makefile.in do-md5sum \
1873 TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
1874 MD5PROG="$(MD5PROG)" \
1875 SUPPORT_FILES="$(SUPPORT_FILES)"
1876 $(MAKE) -f Makefile.in do-djunpack \
1877 TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
1878 MD5PROG="$(MD5PROG)" \
1879 SUPPORT_FILES="$(SUPPORT_FILES)"
bbf6e9e3
AC
1880 $(MAKE) -f Makefile.in do-tar \
1881 TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
1882 MD5PROG="$(MD5PROG)" \
1883 SUPPORT_FILES="$(SUPPORT_FILES)"
1884
1885.PHONY: gdb-taz
1886gdb-taz: gdb-tar $(DEVO_SUPPORT) $(SUPPORT_FILES) texinfo/texinfo.tex
1887 $(MAKE) -f Makefile.in gdb-tar \
1888 TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
1889 MD5PROG="$(MD5PROG)" \
1890 SUPPORT_FILES="$(SUPPORT_FILES)"
1891 $(MAKE) -f Makefile.in do-bz2 \
b35ece4e 1892 TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
fd751128 1893 MD5PROG="$(MD5PROG)" \
b35ece4e
AC
1894 SUPPORT_FILES="$(SUPPORT_FILES)"
1895
1896.PHONY: do-proto-toplev
1897do-proto-toplev: $(DEVO_SUPPORT) $(SUPPORT_FILES) texinfo/texinfo.tex
1898 echo "==> Making $(PACKAGE)-$(VER)/"
252b5132
RH
1899 # Take out texinfo from a few places.
1900 sed -e '/^all\.normal: /s/\all-texinfo //' \
1901 -e '/^ install-texinfo /d' \
1902 <Makefile.in >tmp
1903 mv -f tmp Makefile.in
1904 #
1905 ./configure sun4
1906 [ -z "$(CONFIGURE_TARGET_MODULES)" ] \
5cec67bf
AO
1907 || $(MAKE) $(CONFIGURE_TARGET_MODULES) \
1908 ALL_GCC="" ALL_GCC_C="" ALL_GCC_CXX="" \
252b5132
RH
1909 CC_FOR_TARGET="$(CC)" CXX_FOR_TARGET="$(CXX)"
1910 # Make links, and run "make diststuff" or "make info" when needed.
1911 rm -rf proto-toplev ; mkdir proto-toplev
1912 set -e ; dirs="$(TOOL) $(DEVO_SUPPORT) $(SUPPORT_FILES)" ; \
1913 for d in $$dirs ; do \
1914 if [ -d $$d ]; then \
1915 if [ ! -f $$d/Makefile ] ; then true ; \
1916 elif grep '^diststuff:' $$d/Makefile >/dev/null ; then \
1917 (cd $$d ; $(MAKE) diststuff ) || exit 1 ; \
1918 elif grep '^info:' $$d/Makefile >/dev/null ; then \
1919 (cd $$d ; $(MAKE) info ) || exit 1 ; \
1920 fi ; \
1921 if [ -d $$d/proto-$$d.dir ]; then \
1922 ln -s ../$$d/proto-$$d.dir proto-toplev/$$d ; \
1923 else \
1924 ln -s ../$$d proto-toplev/$$d ; \
1925 fi ; \
1926 else ln -s ../$$d proto-toplev/$$d ; fi ; \
1927 done
5cec67bf 1928 cd etc && $(MAKE) info
252b5132
RH
1929 $(MAKE) distclean
1930 #
1931 mkdir proto-toplev/etc
1932 (cd proto-toplev/etc; \
1933 for i in $(ETC_SUPPORT); do \
1934 ln -s ../../etc/$$i . ; \
1935 done)
1936 #
1937 # Take out texinfo from configurable dirs
1938 rm proto-toplev/configure.in
1939 sed -e '/^host_tools=/s/texinfo //' \
1940 <configure.in >proto-toplev/configure.in
1941 #
1942 mkdir proto-toplev/texinfo
1943 ln -s ../../texinfo/texinfo.tex proto-toplev/texinfo/
252b5132
RH
1944 if test -r texinfo/util/tex3patch ; then \
1945 mkdir proto-toplev/texinfo/util && \
1946 ln -s ../../../texinfo/util/tex3patch proto-toplev/texinfo/util ; \
1947 else true; fi
1948 chmod -R og=u . || chmod og=u `find . -print`
b35ece4e 1949 #
43e64072
NC
1950 # Create .gmo files from .po files.
1951 for f in `find . -name '*.po' -type f -print`; do \
1952 msgfmt -o `echo $$f | sed -e 's/\.po$$/.gmo/'` $$f ; \
1953 done
1954 #
b35ece4e
AC
1955 -rm -f $(PACKAGE)-$(VER)
1956 ln -s proto-toplev $(PACKAGE)-$(VER)
252b5132 1957
bbf6e9e3
AC
1958.PHONY: do-tar
1959do-tar:
1960 echo "==> Making $(PACKAGE)-$(VER).tar"
1961 -rm -f $(PACKAGE)-$(VER).tar
82b43a09
AC
1962 find $(PACKAGE)-$(VER) -follow -name CVS -prune -o -type f -print \
1963 | tar cTfh - $(PACKAGE)-$(VER).tar
bbf6e9e3
AC
1964
1965.PHONY: do-bz2
1966do-bz2:
1967 echo "==> Bzipping $(PACKAGE)-$(VER).tar.bz2"
1968 -rm -f $(PACKAGE)-$(VER).tar.bz2
6dcbc97b 1969 $(BZIPPROG) -v -9 $(PACKAGE)-$(VER).tar
252b5132 1970
b35ece4e
AC
1971.PHONY: do-md5sum
1972do-md5sum:
1973 echo "==> Adding md5 checksum to top-level directory"
82b43a09
AC
1974 cd proto-toplev && find * -follow -name CVS -prune -o -type f -print \
1975 | xargs $(MD5PROG) > ../md5.sum
b35ece4e
AC
1976 mv md5.sum proto-toplev
1977
b5a23627
AC
1978.PHONY: do-djunpack
1979do-djunpack:
1980 echo "==> Adding updated djunpack.bat to top-level directory"
1981 echo - 's /gdb-[0-9\.]*/gdb-'"$(VER)"'/'
1982 sed < djunpack.bat > djunpack.new \
1983 -e 's/gdb-[0-9][0-9\.]*/gdb-'"$(VER)"'/'
1984 mv djunpack.new djunpack.bat
1985 -rm -f proto-toplev/djunpack.bat
1986 ln -s ../djunpack.bat proto-toplev/djunpack.bat
1987
c376f4ed 1988TEXINFO_SUPPORT= texinfo/texinfo.tex
252b5132
RH
1989DIST_SUPPORT= $(DEVO_SUPPORT) $(TEXINFO_SUPPORT)
1990
c376f4ed 1991.PHONY: gas.tar.bz2
71141bb6 1992GAS_SUPPORT_DIRS= bfd include libiberty opcodes intl setup.com makefile.vms mkdep
c376f4ed 1993gas.tar.bz2: $(DIST_SUPPORT) $(GAS_SUPPORT_DIRS) gas
1107dce2 1994 $(MAKE) -f Makefile.in taz TOOL=gas \
fd751128 1995 MD5PROG="$(MD5PROG)" \
252b5132
RH
1996 SUPPORT_FILES="$(GAS_SUPPORT_DIRS)"
1997
1998# The FSF "binutils" release includes gprof and ld.
c376f4ed 1999.PHONY: binutils.tar.bz2
71141bb6 2000BINUTILS_SUPPORT_DIRS= bfd gas include libiberty opcodes ld gprof intl setup.com makefile.vms mkdep
c376f4ed 2001binutils.tar.bz2: $(DIST_SUPPORT) $(BINUTILS_SUPPORT_DIRS) binutils
1107dce2 2002 $(MAKE) -f Makefile.in taz TOOL=binutils \
fd751128 2003 MD5PROG="$(MD5PROG)" \
08d836d6 2004 SUPPORT_FILES="$(BINUTILS_SUPPORT_DIRS)"
252b5132 2005
c376f4ed 2006.PHONY: gas+binutils.tar.bz2
252b5132 2007GASB_SUPPORT_DIRS= $(GAS_SUPPORT_DIRS) binutils ld gprof
c376f4ed 2008gas+binutils.tar.bz2: $(DIST_SUPPORT) $(GASB_SUPPORT_DIRS) gas
1107dce2 2009 $(MAKE) -f Makefile.in taz TOOL=gas \
fd751128 2010 MD5PROG="$(MD5PROG)" \
08d836d6 2011 SUPPORT_FILES="$(GASB_SUPPORT_DIRS)"
252b5132 2012
252b5132 2013GNATS_SUPPORT_DIRS=include libiberty send-pr
c376f4ed 2014gnats.tar.bz2: $(DIST_SUPPORT) $(GNATS_SUPPORT_DIRS) gnats
252b5132 2015 $(MAKE) -f Makefile.in taz TOOL=gnats \
fd751128 2016 MD5PROG="$(MD5PROG)" \
252b5132
RH
2017 SUPPORT_FILES="$(GNATS_SUPPORT_DIRS)"
2018
c376f4ed 2019.PHONY: gdb.tar.bz2
252b5132 2020GDB_SUPPORT_DIRS= bfd include libiberty mmalloc opcodes readline sim utils intl
c376f4ed 2021gdb.tar.bz2: $(DIST_SUPPORT) $(GDB_SUPPORT_DIRS) gdb
b35ece4e 2022 $(MAKE) -f Makefile.in gdb-taz TOOL=gdb \
fd751128 2023 MD5PROG="$(MD5PROG)" \
6dcbc97b 2024 SUPPORT_FILES="$(GDB_SUPPORT_DIRS)"
bbf6e9e3
AC
2025.PHONY: gdb.tar
2026gdb.tar: $(DIST_SUPPORT) $(GDB_SUPPORT_DIRS) gdb
2027 $(MAKE) -f Makefile.in gdb-tar TOOL=gdb \
2028 MD5PROG="$(MD5PROG)" \
2029 SUPPORT_FILES="$(GDB_SUPPORT_DIRS)"
6dcbc97b 2030
6dcbc97b 2031DEJAGNU_SUPPORT_DIRS= tcl expect libiberty
bbf6e9e3 2032.PHONY: dejagnu.tar.bz2
6dcbc97b
AC
2033dejagnu.tar.bz2: $(DIST_SUPPORT) $(DEJAGNU_SUPPORT_DIRS) dejagnu
2034 $(MAKE) -f Makefile.in taz TOOL=dejagnu \
fd751128 2035 MD5PROG="$(MD5PROG)" \
6dcbc97b
AC
2036 SUPPORT_FILES="$(DEJAGNU_SUPPORT_DIRS)"
2037
2038.PHONY: gdb+dejagnu.tar.bz2
2039GDBD_SUPPORT_DIRS= $(GDB_SUPPORT_DIRS) tcl expect dejagnu
2040gdb+dejagnu.tar.bz2: $(DIST_SUPPORT) $(GDBD_SUPPORT_DIRS) gdb
b35ece4e 2041 $(MAKE) -f Makefile.in gdb-taz TOOL=gdb PACKAGE=gdb+dejagnu \
fd751128 2042 MD5PROG="$(MD5PROG)" \
6dcbc97b 2043 SUPPORT_FILES="$(GDBD_SUPPORT_DIRS)"
bbf6e9e3
AC
2044.PHONY: gdb+dejagnu.tar
2045gdb+dejagnu.tar: $(DIST_SUPPORT) $(GDBD_SUPPORT_DIRS) gdb
2046 $(MAKE) -f Makefile.in gdb-tar TOOL=gdb PACKAGE=gdb+dejagnu \
2047 MD5PROG="$(MD5PROG)" \
2048 SUPPORT_FILES="$(GDBD_SUPPORT_DIRS)"
6dcbc97b
AC
2049
2050.PHONY: insight.tar.bz2
2051INSIGHT_SUPPORT_DIRS= $(GDB_SUPPORT_DIRS) tcl tk itcl tix libgui
2052insight.tar.bz2: $(DIST_SUPPORT) $(GDB_SUPPORT_DIRS) gdb
b35ece4e 2053 $(MAKE) -f Makefile.in gdb-taz TOOL=gdb PACKAGE=insight \
fd751128 2054 MD5PROG="$(MD5PROG)" \
6dcbc97b 2055 SUPPORT_FILES="$(INSIGHT_SUPPORT_DIRS)"
bbf6e9e3
AC
2056.PHONY: insight.tar
2057insight.tar: $(DIST_SUPPORT) $(GDB_SUPPORT_DIRS) gdb
2058 $(MAKE) -f Makefile.in gdb-tar TOOL=gdb PACKAGE=insight \
2059 MD5PROG="$(MD5PROG)" \
2060 SUPPORT_FILES="$(INSIGHT_SUPPORT_DIRS)"
6dcbc97b
AC
2061
2062.PHONY: insight+dejagnu.tar.bz2
2063INSIGHTD_SUPPORT_DIRS= $(INSIGHT_SUPPORT_DIRS) expect dejagnu
2064insight+dejagnu.tar.bz2: $(DIST_SUPPORT) $(INSIGHTD_SUPPORT_DIRS) gdb
b35ece4e 2065 $(MAKE) -f Makefile.in gdb-taz TOOL=gdb PACKAGE="insight+dejagnu" \
fd751128 2066 MD5PROG="$(MD5PROG)" \
6dcbc97b 2067 SUPPORT_FILES="$(INSIGHTD_SUPPORT_DIRS)"
bbf6e9e3
AC
2068.PHONY: insight+dejagnu.tar
2069insight+dejagnu.tar: $(DIST_SUPPORT) $(INSIGHTD_SUPPORT_DIRS) gdb
2070 $(MAKE) -f Makefile.in gdb-tar TOOL=gdb PACKAGE="insight+dejagnu" \
2071 MD5PROG="$(MD5PROG)" \
2072 SUPPORT_FILES="$(INSIGHTD_SUPPORT_DIRS)"
252b5132 2073
c376f4ed 2074.PHONY: newlib.tar.bz2
252b5132
RH
2075NEWLIB_SUPPORT_DIRS=libgloss
2076# taz configures for the sun4 target which won't configure newlib.
2077# We need newlib configured so that the .info files are made.
2078# Unfortunately, it is not enough to just configure newlib separately:
2079# taz will build the .info files but since SUBDIRS won't contain newlib,
2080# distclean won't be run (leaving Makefile, config.status, and the tmp files
2081# used in building the .info files, eg: *.def, *.ref).
2082# The problem isn't solvable however without a lot of extra work because
2083# target libraries are built in subdir $(target_alias) which gets nuked during
2084# the make distclean. For now punt on the issue of shipping newlib info files
2085# with newlib net releases and wait for a day when some native target (sun4?)
2086# supports newlib (if only minimally).
c376f4ed 2087newlib.tar.bz2: $(DIST_SUPPORT) $(NEWLIB_SUPPORT_DIRS) newlib
252b5132 2088 $(MAKE) -f Makefile.in taz TOOL=newlib \
fd751128 2089 MD5PROG="$(MD5PROG)" \
252b5132
RH
2090 SUPPORT_FILES="$(NEWLIB_SUPPORT_DIRS)" \
2091 DEVO_SUPPORT="$(DEVO_SUPPORT) COPYING.NEWLIB" newlib
2092
2093.NOEXPORT:
2094MAKEOVERRIDES=
2095
2096# end of Makefile.in
This page took 0.283896 seconds and 4 git commands to generate.