2 # Makefile for directory with subdirs to build.
3 # Copyright (C) 1990, 91, 92, 93, 94, 95, 96, 97, 1998
4 # Free Software Foundation
6 # This file is free software; you can redistribute it and/or modify
7 # it under the terms of the GNU General Public License as published by
8 # the Free Software Foundation; either version 2 of the License, or
9 # (at your option) any later version.
11 # This program is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 # GNU General Public License for more details.
16 # You should have received a copy of the GNU General Public License
17 # along with this program; if not, write to the Free Software
18 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
24 exec_prefix = $(prefix)
26 bindir=${exec_prefix}/bin
27 sbindir
=${exec_prefix}/sbin
28 libexecdir
=${exec_prefix}/libexec
29 datadir=${prefix}/share
30 sysconfdir
=${prefix}/etc
31 sharedstatedir
=${prefix}/com
32 localstatedir
=${prefix}/var
33 libdir=${exec_prefix}/lib
34 includedir=${prefix}/include
35 oldincludedir=/usr
/include
36 infodir=${prefix}/info
39 tooldir
= $(exec_prefix)/$(target
)
41 program_transform_name
=
43 man1dir = $(mandir)/man1
44 man2dir = $(mandir)/man2
45 man3dir = $(mandir)/man3
46 man4dir = $(mandir)/man4
47 man5dir = $(mandir)/man5
48 man6dir = $(mandir)/man6
49 man7dir = $(mandir)/man7
50 man8dir = $(mandir)/man8
51 man9dir = $(mandir)/man9
52 infodir = $(prefix)/info
53 includedir = $(prefix)/include
54 # Directory in which the compiler finds executables, libraries, etc.
55 libsubdir
= $(libdir)/gcc-lib
/$(target_alias
)/$(gcc_version
)
60 # INSTALL_PROGRAM_ARGS is changed by configure.in to use -x for a
62 INSTALL_PROGRAM_ARGS
=
64 INSTALL
= $(SHELL
) $$s/install-sh
-c
65 INSTALL_PROGRAM
= $(INSTALL
) $(INSTALL_PROGRAM_ARGS
)
66 INSTALL_SCRIPT
= $(INSTALL
)
67 INSTALL_DATA
= $(INSTALL
) -m
644
69 INSTALL_DOSREL
= install-dosrel-fake
76 # Special variables passed down in EXTRA_GCC_FLAGS. They are defined
77 # here so that they can be overridden by Makefile fragments.
78 HOST_CC
= $(CC_FOR_BUILD
)
80 HOST_PREFIX_1
= loser-
82 # These flag values are normally overridden by the configure script.
87 CFLAGS_FOR_TARGET
= $(CFLAGS
)
89 LIBCFLAGS_FOR_TARGET
= $(CFLAGS_FOR_TARGET
)
93 CHILLFLAGS
= $(CFLAGS
)
97 # Use -O2 to stress test the compiler.
98 LIBCXXFLAGS
= $(CXXFLAGS
) -fno-implicit-templates
99 CXXFLAGS_FOR_TARGET
= $(CXXFLAGS
)
100 LIBCXXFLAGS_FOR_TARGET
= $(CXXFLAGS_FOR_TARGET
) -fno-implicit-templates
111 # Not plain GZIP, since gzip looks there for extra command-line options.
114 # These values are substituted by configure.
119 BISON
= `if [ -f $$r/bison/bison ] ; then \
120 echo $$r/bison/bison -L $$s/bison/ ; \
125 YACC
= `if [ -f $$r/bison/bison ] ; then \
126 echo $$r/bison/bison -y -L $$s/bison/ ; \
127 elif [ -f $$r/byacc/byacc ] ; then \
128 echo $$r/byacc/byacc ; \
130 echo ${DEFAULT_YACC} ; \
133 LEX
= `if [ -f $$r/flex/flex ] ; \
134 then echo $$r/flex/flex ; \
135 else echo ${DEFAULT_LEX} ; fi`
137 M4
= `if [ -f $$r/m4/m4 ] ; \
138 then echo $$r/m4/m4 ; \
139 else echo ${DEFAULT_M4} ; fi`
141 MAKEINFO
= `if [ -f $$r/texinfo/makeinfo/Makefile ] ; \
142 then echo $$r/texinfo/makeinfo/makeinfo ; \
143 else echo makeinfo ; fi`
145 # This just becomes part of the MAKEINFO definition passed down to
146 # sub-makes. It lets flags be given on the command line while still
147 # using the makeinfo from the object tree.
150 EXPECT
= `if [ -f $$r/expect/expect ] ; \
151 then echo $$r/expect/expect ; \
152 else echo expect ; fi`
154 RUNTEST
= `if [ -f $$s/dejagnu/runtest ] ; \
155 then echo $$s/dejagnu/runtest ; \
156 else echo runtest ; fi`
159 # compilers to use to create programs which must be run in the build
162 CXX_FOR_BUILD
= $(CXX
)
164 SUBDIRS
= "this is set via configure, don't edit this"
167 # This is set by the configure script to the list of directories which
168 # should be built using the target tools.
169 TARGET_CONFIGDIRS
= libiberty libgloss newlib libio librx libstdc
++ libg
++ winsup opcodes libstub cygmon libf2c libchill libobjc
171 # Target libraries are put under this directory:
172 # Changed by configure to $(target_alias) if cross.
175 # This is set by the configure script to the arguments passed to configure.
178 # This is set by configure to REALLY_SET_LIB_PATH if --enable-shared
182 # This is the name of the environment variable used for the path to
183 # the libraries. This may be changed by configure.in.
184 RPATH_ENVVAR
= LD_LIBRARY_PATH
186 # configure.in sets SET_LIB_PATH to this if --enable-shared was used.
187 REALLY_SET_LIB_PATH
= \
188 $(RPATH_ENVVAR
)=$$r/bfd
:$$r/opcodes
:$$$(RPATH_ENVVAR
); \
189 export $(RPATH_ENVVAR
);
192 INSTALL_TARGET
= installdirs \
195 $(INSTALL_TARGET_MODULES
) \
196 $(INSTALL_X11_MODULES
) \
199 INSTALL_TARGET_CROSS
= installdirs \
202 $(INSTALL_TARGET_MODULES
) \
203 $(INSTALL_X11_MODULES
) \
207 if [ -f $$r/gcc/xgcc ] ; then \
208 if [ -f $$r/$(TARGET_SUBDIR)/newlib/Makefile ] ; then \
209 if [ -f $$r/$(TARGET_SUBDIR)/winsup/Makefile ] ; then \
210 echo $$r/gcc/xgcc -B$$r/gcc/ -B$$r/$(TARGET_SUBDIR)/newlib/ -L$$r/$(TARGET_SUBDIR)/winsup -idirafter $$r/$(TARGET_SUBDIR)/newlib/targ-include -idirafter $$s/newlib/libc/include -nostdinc; \
212 echo $$r/gcc/xgcc -B$$r/gcc/ -idirafter $$r/$(TARGET_SUBDIR)/newlib/targ-include -idirafter $$s/newlib/libc/include -nostdinc; \
215 echo $$r/gcc/xgcc -B$$r/gcc/; \
218 if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
221 t='$(program_transform_name)'; echo gcc | sed -e 's/x/x/' $$t; \
225 # If CC_FOR_TARGET is not overriden on the command line, then this
226 # variable is passed down to the gcc Makefile, where it is used to
227 # build libgcc2.a. We define it here so that it can itself be
228 # overridden on the command line.
229 GCC_FOR_TARGET
= $$r/gcc
/xgcc
-B
$$r/gcc
/
231 CHILL_FOR_TARGET
= ` \
232 if [ -f $$r/gcc/xgcc ] ; then \
233 echo $$r/gcc/xgcc -B$$r/gcc/ -L$$r/gcc/ch/runtime/; \
235 if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
238 t='$(program_transform_name)'; echo gcc | sed -e 's/x/x/' $$t; \
243 if [ -f $$r/gcc/xgcc ] ; then \
244 if [ -f $$r/$(TARGET_SUBDIR)/newlib/Makefile ] ; then \
245 if [ -f $$r/$(TARGET_SUBDIR)/winsup/Makefile ] ; then \
246 echo $$r/gcc/xgcc -B$$r/gcc/ -B$$r/$(TARGET_SUBDIR)/newlib/ -L$$r/winsup -idirafter $$r/$(TARGET_SUBDIR)/newlib/targ-include -idirafter $$s/newlib/libc/include -nostdinc; \
248 echo $$r/gcc/xgcc -B$$r/gcc/ -idirafter $$r/$(TARGET_SUBDIR)/newlib/targ-include -idirafter $$s/newlib/libc/include -nostdinc; \
251 echo $$r/gcc/xgcc -B$$r/gcc/; \
254 if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
257 t='$(program_transform_name)'; echo c++ | sed -e 's/x/x/' $$t; \
262 if [ -f $$r/gas/as-new ] ; then \
263 echo $$r/gas/as-new ; \
265 if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
268 t='$(program_transform_name)'; echo as | sed -e 's/x/x/' $$t ; \
273 if [ -f $$r/ld/ld-new ] ; then \
274 echo $$r/ld/ld-new ; \
276 if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
279 t='$(program_transform_name)'; echo ld | sed -e 's/x/x/' $$t ; \
283 DLLTOOL_FOR_TARGET
= ` \
284 if [ -f $$r/binutils/dlltool ] ; then \
285 echo $$r/binutils/dlltool ; \
287 if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
290 t='$(program_transform_name)'; echo dlltool | sed -e 's/x/x/' $$t ; \
294 WINDRES_FOR_TARGET
= ` \
295 if [ -f $$r/binutils/windres ] ; then \
296 echo $$r/binutils/windres ; \
298 if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
301 t='$(program_transform_name)'; echo windres | sed -e 's/x/x/' $$t ; \
306 if [ -f $$r/binutils/ar ] ; then \
307 echo $$r/binutils/ar ; \
309 if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
312 t='$(program_transform_name)'; echo ar | sed -e 's/x/x/' $$t ; \
316 RANLIB_FOR_TARGET
= ` \
317 if [ -f $$r/binutils/ranlib ] ; then \
318 echo $$r/binutils/ranlib ; \
320 if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
323 t='$(program_transform_name)'; echo ranlib | sed -e 's/x/x/' $$t ; \
328 if [ -f $$r/binutils/nm-new ] ; then \
329 echo $$r/binutils/nm-new ; \
331 if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
334 t='$(program_transform_name)'; echo nm | sed -e 's/x/x/' $$t ; \
338 # The first rule in the file had better be this one. Don't put any above it.
339 # This lives here to allow makefile fragments to contain dependencies.
343 # These can be overridden by config/mt-*.
344 # The _TARGET_ is because they're specified in mt-foo.
345 # The _HOST_ is because they're programs that run on the host.
346 EXTRA_TARGET_HOST_ALL_MODULES
=
347 EXTRA_TARGET_HOST_INSTALL_MODULES
=
348 EXTRA_TARGET_HOST_CHECK_MODULES
=
350 #### host and target specific makefile fragments come in here.
353 # Flags to pass down to all sub-makes.
354 # Please keep these in alphabetical order.
355 BASE_FLAGS_TO_PASS
= \
356 "AR_FLAGS=$(AR_FLAGS)" \
357 "AR_FOR_TARGET=$(AR_FOR_TARGET)" \
358 "AS_FOR_TARGET=$(AS_FOR_TARGET)" \
360 "CC_FOR_BUILD=$(CC_FOR_BUILD)" \
361 "CC_FOR_TARGET=$(CC_FOR_TARGET)" \
363 "CFLAGS_FOR_TARGET=$(CFLAGS_FOR_TARGET)" \
364 "CHILLFLAGS=$(CHILLFLAGS)" \
365 "CHILL_FOR_TARGET=$(CHILL_FOR_TARGET)" \
366 "CHILL_LIB=$(CHILL_LIB)" \
367 "CXX_FOR_BUILD=$(CXX_FOR_BUILD)" \
368 "CXXFLAGS=$(CXXFLAGS)" \
369 "CXXFLAGS_FOR_TARGET=$(CXXFLAGS_FOR_TARGET)" \
370 "CXX_FOR_TARGET=$(CXX_FOR_TARGET)" \
371 "DLLTOOL_FOR_TARGET=$(DLLTOOL_FOR_TARGET)" \
372 "INSTALL=$(INSTALL)" \
373 "INSTALL_DATA=$(INSTALL_DATA)" \
374 "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \
375 "INSTALL_SCRIPT=$(INSTALL_SCRIPT)" \
376 "LDFLAGS=$(LDFLAGS)" \
378 "LD_FOR_TARGET=$(LD_FOR_TARGET)" \
379 "LIBCFLAGS=$(LIBCFLAGS)" \
380 "LIBCFLAGS_FOR_TARGET=$(LIBCFLAGS_FOR_TARGET)" \
381 "LIBCXXFLAGS=$(LIBCXXFLAGS)" \
382 "LIBCXXFLAGS_FOR_TARGET=$(LIBCXXFLAGS_FOR_TARGET)" \
385 "MAKEINFO=$(MAKEINFO) $(MAKEINFOFLAGS)" \
386 "NM_FOR_TARGET=$(NM_FOR_TARGET)" \
387 "RANLIB_FOR_TARGET=$(RANLIB_FOR_TARGET)" \
388 "RPATH_ENVVAR=$(RPATH_ENVVAR)" \
391 "RUNTEST=$(RUNTEST)" \
392 "RUNTESTFLAGS=$(RUNTESTFLAGS)" \
393 "TARGET_SUBDIR=$(TARGET_SUBDIR)" \
394 "WINDRES_FOR_TARGET=$(WINDRES_FOR_TARGET)" \
397 "datadir=$(datadir)" \
398 "exec_prefix=$(exec_prefix)" \
399 "includedir=$(includedir)" \
400 "infodir=$(infodir)" \
402 "libexecdir=$(libexecdir)" \
403 "lispdir=$(lispdir)" \
404 "localstatedir=$(localstatedir)" \
406 "oldincludedir=$(oldincludedir)" \
408 "sbindir=$(sbindir)" \
409 "sharedstatedir=$(sharedstatedir)" \
410 "sysconfdir=$(sysconfdir)" \
411 "tooldir=$(tooldir)" \
412 "gxx_include_dir=$(gxx_include_dir)" \
413 "gcc_version=$(gcc_version)" \
414 "gcc_version_trigger=$(gcc_version_trigger)" \
415 "target_alias=$(target_alias)" \
416 "libsubdir=$(libsubdir)"
418 # Flags to pass down to most sub-makes, in which we're building with
419 # the host environment.
420 # If any variables are added here, they must be added to do-*, below.
426 'DLLTOOL=$(DLLTOOL)' \
432 FLAGS_TO_PASS
= $(BASE_FLAGS_TO_PASS
) $(EXTRA_HOST_FLAGS
)
434 # Flags that are concerned with the location of the X11 include files
437 # NOTE: until the top-level is getting the values via autoconf, it only
438 # causes problems to have this top-level Makefile overriding the autoconf-set
439 # values in child directories. Only variables that don't conflict with
440 # autoconf'ed ones should be passed by X11_FLAGS_TO_PASS for now.
442 X11_FLAGS_TO_PASS
= \
443 'X11_EXTRA_CFLAGS=$(X11_EXTRA_CFLAGS)' \
444 'X11_EXTRA_LIBS=$(X11_EXTRA_LIBS)'
446 # Flags to pass down to makes which are built with the target environment.
447 # The double $ decreases the length of the command line; the variables
448 # are set in BASE_FLAGS_TO_PASS, and the sub-make will expand them.
449 # If any variables are added here, they must be added to do-*, below.
450 EXTRA_TARGET_FLAGS
= \
451 'AR=$$(AR_FOR_TARGET)' \
452 'AS=$$(AS_FOR_TARGET)' \
453 'CC=$$(CC_FOR_TARGET)' \
454 'CFLAGS=$$(CFLAGS_FOR_TARGET)' \
455 'CXX=$$(CXX_FOR_TARGET)' \
456 'CXXFLAGS=$$(CXXFLAGS_FOR_TARGET)' \
457 'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \
458 'LD=$$(LD_FOR_TARGET)' \
459 'LIBCFLAGS=$$(LIBCFLAGS_FOR_TARGET)' \
460 'LIBCXXFLAGS=$$(LIBCXXFLAGS_FOR_TARGET)' \
461 'NM=$$(NM_FOR_TARGET)' \
462 'RANLIB=$$(RANLIB_FOR_TARGET)' \
463 'WINDRES=$$(WINDRES_FOR_TARGET)'
465 TARGET_FLAGS_TO_PASS
= $(BASE_FLAGS_TO_PASS
) $(EXTRA_TARGET_FLAGS
)
467 # Flags to pass down to gcc. gcc builds a library, libgcc.a, so it
468 # unfortunately needs the native compiler and the target ar and
470 # If any variables are added here, they must be added to do-*, below.
471 # The HOST_* variables are a special case, which are used for the gcc
472 # cross-building scheme.
474 'AR=$$(AR_FOR_TARGET)' \
478 'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \
479 'HOST_CC=$(CC_FOR_BUILD)' \
480 'HOST_PREFIX=$(HOST_PREFIX)' \
481 'HOST_PREFIX_1=$(HOST_PREFIX_1)' \
483 'RANLIB=$$(RANLIB_FOR_TARGET)' \
484 'WINDRES=$$(WINDRES_FOR_TARGET)' \
485 "GCC_FOR_TARGET=$(GCC_FOR_TARGET)" \
486 "`echo 'LANGUAGES=$(LANGUAGES)' | sed -e s/.*=$$/XFOO=/`" \
487 "`echo 'STMP_FIXPROTO=$(STMP_FIXPROTO)' | sed -e s/.*=$$/XFOO=/`" \
488 "`echo 'LIMITS_H_TEST=$(LIMITS_H_TEST)' | sed -e s/.*=$$/XFOO=/`" \
489 "`echo 'LIBGCC1_TEST=$(LIBGCC1_TEST)' | sed -e s/.*=$$/XFOO=/`" \
490 "`echo 'LIBGCC2_CFLAGS=$(LIBGCC2_CFLAGS)' | sed -e s/.*=$$/XFOO=/`" \
491 "`echo 'LIBGCC2_DEBUG_CFLAGS=$(LIBGCC2_DEBUG_CFLAGS)' | sed -e s/.*=$$/XFOO=/`" \
492 "`echo 'LIBGCC2_INCLUDES=$(LIBGCC2_INCLUDES)' | sed -e s/.*=$$/XFOO=/`" \
493 "`echo 'ENQUIRE=$(ENQUIRE)' | sed -e s/.*=$$/XFOO=/`" \
494 "`echo 'BOOT_CFLAGS=$(BOOT_CFLAGS)' | sed -e s/.*=$$/XFOO=/`"
496 GCC_FLAGS_TO_PASS
= $(BASE_FLAGS_TO_PASS
) $(EXTRA_GCC_FLAGS
)
498 # This is a list of the targets for all of the modules which are compiled
499 # using $(FLAGS_TO_PASS).
562 $(EXTRA_TARGET_HOST_ALL_MODULES
)
564 # This is a list of the check targets for all of the modules which are
565 # compiled using $(FLAGS_TO_PASS).
567 # The list is in two parts. The first lists those tools which
568 # are tested as part of the host's native tool-chain, and not
569 # tested in a cross configuration.
570 NATIVE_CHECK_MODULES
= \
575 CROSS_CHECK_MODULES
= \
632 $(EXTRA_TARGET_HOST_CHECK_MODULES
)
634 CHECK_MODULES
=$(NATIVE_CHECK_MODULES
) $(CROSS_CHECK_MODULES
)
636 # This is a list of the install targets for all of the modules which are
637 # compiled using $(FLAGS_TO_PASS).
638 # We put install-opcodes before install-binutils because the installed
639 # binutils might be on PATH, and they might need the shared opcodes
641 # We put install-tcl before install-itcl because itcl wants to run a
642 # program on installation which uses the Tcl libraries.
705 $(EXTRA_TARGET_HOST_INSTALL_MODULES
)
707 # This is a list of the targets for all of the modules which are compiled
708 # using $(X11_FLAGS_TO_PASS).
720 # This is a list of the check targets for all of the modules which are
721 # compiled using $(X11_FLAGS_TO_PASS).
722 CHECK_X11_MODULES
= \
732 # This is a list of the install targets for all the modules which are
733 # compiled using $(X11_FLAGS_TO_PASS).
734 INSTALL_X11_MODULES
= \
745 # This is a list of the targets for all of the modules which are compiled
746 # using $(TARGET_FLAGS_TO_PASS).
747 ALL_TARGET_MODULES
= \
749 all-target-libstdc
++ \
754 all-target-libchill \
757 all-target-libgloss \
758 all-target-libiberty \
760 all-target-examples \
764 # This is a list of the configure targets for all of the modules which
765 # are compiled using the target tools.
766 CONFIGURE_TARGET_MODULES
= \
767 configure-target-libio \
768 configure-target-libstdc
++ \
769 configure-target-librx \
770 configure-target-libg
++ \
771 configure-target-newlib \
772 configure-target-libf2c \
773 configure-target-libchill \
774 configure-target-libobjc \
775 configure-target-winsup \
776 configure-target-libgloss \
777 configure-target-libiberty \
778 configure-target-gperf \
779 configure-target-examples \
780 configure-target-libstub \
781 configure-target-cygmon
783 # This is a list of the check targets for all of the modules which are
784 # compiled using $(TARGET_FLAGS_TO_PASS).
785 CHECK_TARGET_MODULES
= \
787 check-target-libstdc
++ \
788 check-target-libg
++ \
789 check-target-newlib \
790 check-target-libf2c \
791 check-target-libchill \
792 check-target-libobjc \
793 check-target-winsup \
794 check-target-libiberty \
797 # This is a list of the install targets for all of the modules which are
798 # compiled using $(TARGET_FLAGS_TO_PASS).
799 INSTALL_TARGET_MODULES
= \
800 install-target-libio \
801 install-target-libstdc
++ \
802 install-target-libg
++ \
803 install-target-newlib \
804 install-target-libf2c \
805 install-target-libchill \
806 install-target-libobjc \
807 install-target-winsup \
808 install-target-libgloss \
809 install-target-libiberty \
812 # This is a list of the targets for which we can do a clean-{target}.
877 # All of the target modules that can be cleaned
878 CLEAN_TARGET_MODULES
= \
880 clean-target-libstdc
++ \
882 clean-target-libg
++ \
883 clean-target-newlib \
884 clean-target-libf2c \
885 clean-target-libchill \
886 clean-target-libobjc \
887 clean-target-winsup \
888 clean-target-libgloss \
889 clean-target-libiberty \
891 clean-target-examples \
892 clean-target-libstub \
895 # All of the x11 modules that can be cleaned
896 CLEAN_X11_MODULES
= \
907 # The first rule in the file had better be this one. Don't put any above it.
911 # The target built for a native build.
916 $(ALL_TARGET_MODULES
) \
919 # Do a target for all the subdirectories. A ``make do-X'' will do a
920 # ``make X'' in all subdirectories (because, in general, there is a
921 # dependency (below) of X upon do-X, a ``make X'' will also do this,
922 # but it may do additional work as well).
923 # This target ensures that $(BASE_FLAGS_TO_PASS) appears only once,
924 # because it is so large that it can easily overflow the command line
925 # length limit on some systems.
934 do-maintainer-clean \
938 @target
=`echo $@ | sed -e 's/^do-//'`; \
940 s
=`cd $(srcdir); pwd`; export s
; \
942 for i in
$(SUBDIRS
) -dummy-
; do \
943 if
[ -f .
/$$i/Makefile
]; then \
946 for flag in
$(EXTRA_GCC_FLAGS
); do \
947 eval
`echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'|"`; \
951 for flag in
$(EXTRA_HOST_FLAGS
); do \
952 eval
`echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'|"`; \
956 export AR AS CC CXX LD NM RANLIB DLLTOOL WINDRES
; \
958 $(MAKE
) $(BASE_FLAGS_TO_PASS
) "AR=$${AR}" "AS=$${AS}" \
959 "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
960 "RANLIB=$${RANLIB}" \
961 "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
963 then true
; else exit
1; fi
; \
966 @target
=`echo $@ | sed -e 's/^do-//'`; \
968 s
=`cd $(srcdir); pwd`; export s
; \
970 for i in
$(TARGET_CONFIGDIRS
) -dummy-
; do \
971 if
[ -f
$(TARGET_SUBDIR
)/$$i/Makefile
]; then \
972 for flag in
$(EXTRA_TARGET_FLAGS
); do \
973 eval
`echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'|"`; \
975 export AR AS CC CXX LD NM RANLIB DLLTOOL WINDRES
; \
976 if
(cd
$(TARGET_SUBDIR
)/$$i; \
977 $(MAKE
) $(BASE_FLAGS_TO_PASS
) "AR=$${AR}" "AS=$${AS}" \
978 "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
979 "RANLIB=$${RANLIB}" \
980 "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
982 then true
; else exit
1; fi
; \
986 # Here are the targets which correspond to the do-X targets.
988 .PHONY
: info installcheck dvi install-info
989 .PHONY
: clean distclean mostlyclean maintainer-clean
realclean
990 .PHONY
: local-clean local-distclean local-maintainer-clean
992 installcheck: do-installcheck
995 # Make sure makeinfo is built before we do a `make info'.
998 install-info
: do-install-info
dir.
info
999 s
=`cd $(srcdir); pwd`; export s
; \
1000 if
[ -f
dir.
info ] ; then \
1001 $(INSTALL_DATA
) dir.
info $(infodir)/dir.
info ; \
1005 -rm -f
*.a TEMP errs core
*.o
*~ \
#* TAGS *.E *.log
1008 -rm -f Makefile config.status config.cache mh-frag mt-frag
1009 -if
[ "$(TARGET_SUBDIR)" != "." ]; then \
1010 rm -rf
$(TARGET_SUBDIR
); \
1013 local-maintainer-clean
:
1014 @echo
"This command is intended for maintainers to use;"
1015 @echo
"it deletes files that may require special tools to rebuild."
1017 clean: do-clean local-clean
1018 mostlyclean: do-mostlyclean local-clean
1019 distclean: do-distclean local-clean local-distclean
1020 maintainer-clean
: local-maintainer-clean do-maintainer-clean local-clean
1021 maintainer-clean
: local-distclean
1022 realclean: maintainer-clean
1024 # This rule is used to clean specific modules.
1025 .PHONY
: $(CLEAN_MODULES
) $(CLEAN_X11_MODULES
) clean-gcc
1026 $(CLEAN_MODULES
) $(CLEAN_X11_MODULES
) clean-gcc
:
1027 @
dir=`echo $@ | sed -e 's/clean-//'`; \
1028 if
[ -f .
/$${dir}/Makefile
] ; then \
1029 r
=`pwd`; export r
; \
1030 s
=`cd $(srcdir); pwd`; export s
; \
1032 (cd
$${dir}; $(MAKE
) $(FLAGS_TO_PASS
) clean); \
1037 .PHONY
: $(CLEAN_TARGET_MODULES
)
1038 $(CLEAN_TARGET_MODULES
):
1039 @
dir=`echo $@ | sed -e 's/clean-target-//'`; \
1040 rm -f
$(TARGET_SUBDIR
)/$${dir}/multilib.out
$(TARGET_SUBDIR
)/$${dir}/tmpmulti.out
; \
1041 if
[ -f
$(TARGET_SUBDIR
)/$${dir}/Makefile
] ; then \
1042 r
=`pwd`; export r
; \
1043 s
=`cd $(srcdir); pwd`; export s
; \
1045 (cd
$(TARGET_SUBDIR
)/$${dir}; $(MAKE
) $(TARGET_FLAGS_TO_PASS
) clean); \
1050 clean-target
: $(CLEAN_TARGET_MODULES
)
1055 check: $(CHECK_MODULES
) \
1056 $(CHECK_TARGET_MODULES
) \
1057 $(CHECK_X11_MODULES
) \
1060 # Automated reporting of test results.
1062 warning.log
: build.log
1063 $(srcdir)/contrib
/warn_summary build.log
> $@
1066 if
test x
'$(BOOT_CFLAGS)' != x
''; then \
1067 BOOT_CFLAGS
='$(BOOT_CFLAGS)'; export BOOT_CFLAGS
; \
1069 $(srcdir)/contrib
/test_summary
-t
>$@
1071 echo If you really want to send e-mail
, run .
/$@ now
1073 mail-report-with-warnings.log
: warning.log
1074 if
test x
'$(BOOT_CFLAGS)' != x
''; then \
1075 BOOT_CFLAGS
='$(BOOT_CFLAGS)'; export BOOT_CFLAGS
; \
1077 $(srcdir)/contrib
/test_summary
-t
-i warning.log
>$@
1079 echo If you really want to send e-mail
, run .
/$@ now
1081 # Installation targets.
1083 .PHONY
: install install-cross
uninstall source-vault binary-vault vault-install
1084 install: $(INSTALL_TARGET
)
1085 install-cross
: $(INSTALL_TARGET_CROSS
)
1088 @echo
"the uninstall target is not supported in this tree"
1091 $(MAKE
) -f .
/release
/Build-A-Release \
1092 host
=$(host_alias
) source-vault
1095 $(MAKE
) -f .
/release
/Build-A-Release \
1096 host
=$(host_alias
) target
=$(target_alias
)
1099 @if
[ -f .
/release
/vault-install
] ; then \
1100 .
/release
/vault-install
$(host_alias
) $(target_alias
) ; \
1106 install.
all: install-no-fixedincludes
1107 @if
[ -f .
/gcc
/Makefile
] ; then \
1108 r
=`pwd` ; export r
; \
1111 $(MAKE
) $(FLAGS_TO_PASS
) install-headers
) ; \
1116 # inet-install is used because the I*Net wants DejaGNU installed but
1117 # not built. Similarly, gzip is built but not installed.
1119 $(MAKE
) INSTALL_MODULES
="`echo $(INSTALL_MODULES) | sed -e 's/install-dejagnu//' -e 's/install-gzip//'`" install
1121 # install-no-fixedincludes is used because Cygnus can not distribute
1122 # the fixed header files.
1123 .PHONY
: install-no-fixedincludes
1124 install-no-fixedincludes
: \
1126 $(INSTALL_MODULES
) \
1127 $(INSTALL_TARGET_MODULES
) \
1128 $(INSTALL_X11_MODULES
) \
1129 gcc-no-fixedincludes
1131 # Install the gcc headers files, but not the fixed include files,
1132 # which Cygnus is not allowed to distribute. This rule is very
1133 # dependent on the workings of the gcc Makefile.in.
1134 .PHONY
: gcc-no-fixedincludes
1135 gcc-no-fixedincludes
:
1136 @if
[ -f .
/gcc
/Makefile
]; then \
1137 rm -rf gcc
/tmp-include
; \
1138 mv gcc
/include gcc
/tmp-include
2>/dev
/null
; \
1139 mkdir gcc
/include; \
1140 cp
$(srcdir)/gcc
/gsyslimits.h gcc
/include/syslimits.h
; \
1141 touch gcc
/stmp-fixinc gcc
/include/fixed
; \
1142 rm -f gcc
/stmp-headers gcc
/stmp-int-hdrs
; \
1143 r
=`pwd`; export r
; \
1144 s
=`cd $(srcdir); pwd` ; export s
; \
1147 $(MAKE
) $(GCC_FLAGS_TO_PASS
) install); \
1148 rm -rf gcc
/include; \
1149 mv gcc
/tmp-include gcc
/include 2>/dev
/null
; \
1152 # This rule is used to build the modules which use FLAGS_TO_PASS. To
1153 # build a target all-X means to cd to X and make all.
1155 # all-gui, and all-libproc are handled specially because
1156 # they are still experimental, and if they fail to build, that
1157 # shouldn't stop "make all".
1158 .PHONY
: $(ALL_MODULES
) all-gui all-libproc
1159 $(ALL_MODULES
) all-gui all-libproc
:
1160 @
dir=`echo $@ | sed -e 's/all-//'`; \
1161 if
[ -f .
/$${dir}/Makefile
] ; then \
1162 r
=`pwd`; export r
; \
1163 s
=`cd $(srcdir); pwd`; export s
; \
1165 (cd
$${dir}; $(MAKE
) $(FLAGS_TO_PASS
) all); \
1170 # These rules are used to check the modules which use FLAGS_TO_PASS.
1171 # To build a target check-X means to cd to X and make check. Some
1172 # modules are only tested in a native toolchain.
1174 .PHONY
: $(CHECK_MODULES
) $(NATIVE_CHECK_MODULES
) $(CROSS_CHECK_MODULES
)
1175 $(NATIVE_CHECK_MODULES
):
1176 @if
[ "$(host_canonical)" = "$(target_canonical)" ] ; then \
1177 dir=`echo $@ | sed -e 's/check-//'`; \
1178 if
[ -f .
/$${dir}/Makefile
] ; then \
1179 r
=`pwd`; export r
; \
1180 s
=`cd $(srcdir); pwd`; export s
; \
1182 (cd
$${dir}; $(MAKE
) $(FLAGS_TO_PASS
) check); \
1188 $(CROSS_CHECK_MODULES
):
1189 @
dir=`echo $@ | sed -e 's/check-//'`; \
1190 if
[ -f .
/$${dir}/Makefile
] ; then \
1191 r
=`pwd`; export r
; \
1192 s
=`cd $(srcdir); pwd`; export s
; \
1194 (cd
$${dir}; $(MAKE
) $(FLAGS_TO_PASS
) check); \
1199 # This rule is used to install the modules which use FLAGS_TO_PASS.
1200 # To build a target install-X means to cd to X and make install.
1201 .PHONY
: $(INSTALL_MODULES
)
1202 $(INSTALL_MODULES
): installdirs
1203 @
dir=`echo $@ | sed -e 's/install-//'`; \
1204 if
[ -f .
/$${dir}/Makefile
] ; then \
1205 r
=`pwd`; export r
; \
1206 s
=`cd $(srcdir); pwd`; export s
; \
1208 (cd
$${dir}; $(MAKE
) $(FLAGS_TO_PASS
) install); \
1213 # This rule is used to configure the modules which are built with the
1215 .PHONY
: $(CONFIGURE_TARGET_MODULES
)
1216 $(CONFIGURE_TARGET_MODULES
):
1217 @
dir=`echo $@ | sed -e 's/configure-target-//'`; \
1218 if
[ -d
$(TARGET_SUBDIR
)/$${dir} ]; then \
1219 r
=`pwd`; export r
; \
1220 $(CC_FOR_TARGET
) --print-multi-lib
> $(TARGET_SUBDIR
)/$${dir}/tmpmulti.out
2> /dev
/null
; \
1221 if
[ -s
$(TARGET_SUBDIR
)/$${dir}/tmpmulti.out
]; then \
1222 if
[ -f
$(TARGET_SUBDIR
)/$${dir}/multilib.out
]; then \
1223 if cmp
$(TARGET_SUBDIR
)/$${dir}/multilib.out
$(TARGET_SUBDIR
)/$${dir}/tmpmulti.out
> /dev
/null
; then \
1224 rm -f
$(TARGET_SUBDIR
)/$${dir}/tmpmulti.out
; \
1226 echo
"Multilibs changed for $${dir}, reconfiguring"; \
1227 rm -f
$(TARGET_SUBDIR
)/$${dir}/multilib.out
$(TARGET_SUBDIR
)/$${dir}/Makefile
; \
1228 mv
$(TARGET_SUBDIR
)/$${dir}/tmpmulti.out
$(TARGET_SUBDIR
)/$${dir}/multilib.out
; \
1231 mv
$(TARGET_SUBDIR
)/$${dir}/tmpmulti.out
$(TARGET_SUBDIR
)/$${dir}/multilib.out
; \
1234 fi
; exit
0 # break command into two pieces
1235 @
dir=`echo $@ | sed -e 's/configure-target-//'`; \
1236 if
[ ! -d
$(TARGET_SUBDIR
) ]; then \
1238 elif
[ -f
$(TARGET_SUBDIR
)/$${dir}/Makefile
] ; then \
1240 elif echo
" $(TARGET_CONFIGDIRS) " | grep
" $${dir} " >/dev
/null
2>&1; then \
1241 if
[ -d
$(srcdir)/$${dir} ]; then \
1242 [ -d
$(TARGET_SUBDIR
)/$${dir} ] || mkdir
$(TARGET_SUBDIR
)/$${dir};\
1243 r
=`pwd`; export r
; \
1244 s
=`cd $(srcdir); pwd`; export s
; \
1246 AR
="$(AR_FOR_TARGET)"; export AR
; \
1247 AS
="$(AS_FOR_TARGET)"; export AS
; \
1248 CC
="$(CC_FOR_TARGET)"; export CC
; \
1249 CFLAGS
="$(CFLAGS_FOR_TARGET)"; export CFLAGS
; \
1250 CXX
="$(CXX_FOR_TARGET)"; export CXX
; \
1251 CXXFLAGS
="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS
; \
1252 DLLTOOL
="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL
; \
1253 LD
="$(LD_FOR_TARGET)"; export LD
; \
1254 LDFLAGS
="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS
; \
1255 NM
="$(NM_FOR_TARGET)"; export NM
; \
1256 RANLIB
="$(RANLIB_FOR_TARGET)"; export RANLIB
; \
1257 WINDRES
="$(WINDRES_FOR_TARGET)"; export WINDRES
; \
1258 echo Configuring in
$(TARGET_SUBDIR
)/$${dir}; \
1259 cd
$(TARGET_SUBDIR
)/$${dir}; \
1262 topdir
=$(srcdir) ;; \
1264 case
"$(TARGET_SUBDIR)" in \
1265 .
) topdir
="../$(srcdir)" ;; \
1266 *) topdir
="../../$(srcdir)" ;; \
1269 if
[ "$(srcdir)" = "." ] ; then \
1270 if
[ "$(TARGET_SUBDIR)" != "." ] ; then \
1271 if
$(SHELL
) $$s/symlink-tree
$${topdir}/$${dir} "no-such-file" ; then \
1272 if
[ -f Makefile
]; then \
1273 if
$(MAKE
) distclean; then \
1287 srcdiroption
="--srcdir=."; \
1290 srcdiroption
="--srcdir=$${topdir}/$${dir}"; \
1291 libsrcdir
="$$s/$${dir}"; \
1293 if
[ -f
$${libsrcdir}/configure
] ; then \
1294 rm -f no-such-file
; \
1295 CONFIG_SITE
=no-such-file
$(SHELL
) $${libsrcdir}/configure \
1296 $(CONFIG_ARGUMENTS
) $${srcdiroption} \
1297 --with-target-subdir
="$(TARGET_SUBDIR)"; \
1299 rm -f no-such-file
; \
1300 CONFIG_SITE
=no-such-file
$(SHELL
) $$s/configure \
1301 $(CONFIG_ARGUMENTS
) $${srcdiroption} \
1302 --with-target-subdir
="$(TARGET_SUBDIR)"; \
1311 # This rule is used to build the modules which use TARGET_FLAGS_TO_PASS.
1312 # To build a target all-X means to cd to X and make all.
1313 .PHONY
: $(ALL_TARGET_MODULES
)
1314 $(ALL_TARGET_MODULES
):
1315 @
dir=`echo $@ | sed -e 's/all-target-//'`; \
1316 if
[ -f
$(TARGET_SUBDIR
)/$${dir}/Makefile
] ; then \
1317 r
=`pwd`; export r
; \
1318 s
=`cd $(srcdir); pwd`; export s
; \
1320 (cd
$(TARGET_SUBDIR
)/$${dir}; $(MAKE
) $(TARGET_FLAGS_TO_PASS
) all); \
1325 # This rule is used to check the modules which use TARGET_FLAGS_TO_PASS.
1326 # To build a target install-X means to cd to X and make install.
1327 .PHONY
: $(CHECK_TARGET_MODULES
)
1328 $(CHECK_TARGET_MODULES
):
1329 @
dir=`echo $@ | sed -e 's/check-target-//'`; \
1330 if
[ -f
$(TARGET_SUBDIR
)/$${dir}/Makefile
] ; then \
1331 r
=`pwd`; export r
; \
1332 s
=`cd $(srcdir); pwd`; export s
; \
1334 (cd
$(TARGET_SUBDIR
)/$${dir};$(MAKE
) $(TARGET_FLAGS_TO_PASS
) check);\
1339 # This rule is used to install the modules which use
1340 # TARGET_FLAGS_TO_PASS. To build a target install-X means to cd to X
1342 .PHONY
: $(INSTALL_TARGET_MODULES
)
1343 $(INSTALL_TARGET_MODULES
): installdirs
1344 @
dir=`echo $@ | sed -e 's/install-target-//'`; \
1345 if
[ -f
$(TARGET_SUBDIR
)/$${dir}/Makefile
] ; then \
1346 r
=`pwd`; export r
; \
1347 s
=`cd $(srcdir); pwd`; export s
; \
1349 (cd
$(TARGET_SUBDIR
)/$${dir}; \
1350 $(MAKE
) $(TARGET_FLAGS_TO_PASS
) install); \
1355 # This rule is used to build the modules which use X11_FLAGS_TO_PASS.
1356 # To build a target all-X means to cd to X and make all.
1357 .PHONY
: $(ALL_X11_MODULES
)
1359 @
dir=`echo $@ | sed -e 's/all-//'`; \
1360 if
[ -f .
/$${dir}/Makefile
] ; then \
1361 r
=`pwd`; export r
; \
1362 s
=`cd $(srcdir); pwd`; export s
; \
1365 $(MAKE
) $(FLAGS_TO_PASS
) $(X11_FLAGS_TO_PASS
) all); \
1370 # This rule is used to check the modules which use X11_FLAGS_TO_PASS.
1371 # To build a target check-X means to cd to X and make all.
1372 .PHONY
: $(CHECK_X11_MODULES
)
1373 $(CHECK_X11_MODULES
):
1374 @
dir=`echo $@ | sed -e 's/check-//'`; \
1375 if
[ -f .
/$${dir}/Makefile
] ; then \
1376 r
=`pwd`; export r
; \
1377 s
=`cd $(srcdir); pwd`; export s
; \
1380 $(MAKE
) $(FLAGS_TO_PASS
) $(X11_FLAGS_TO_PASS
) check); \
1385 # This rule is used to install the modules which use X11_FLAGS_TO_PASS.
1386 # To build a target install-X means to cd to X and make install.
1387 .PHONY
: $(INSTALL_X11_MODULES
)
1388 $(INSTALL_X11_MODULES
): installdirs
1389 @
dir=`echo $@ | sed -e 's/install-//'`; \
1390 if
[ -f .
/$${dir}/Makefile
] ; then \
1391 r
=`pwd`; export r
; \
1392 s
=`cd $(srcdir); pwd`; export s
; \
1395 $(MAKE
) $(FLAGS_TO_PASS
) $(X11_FLAGS_TO_PASS
) install); \
1400 # gcc is the only module which uses GCC_FLAGS_TO_PASS.
1403 @if
[ -f .
/gcc
/Makefile
] ; then \
1404 r
=`pwd`; export r
; \
1405 s
=`cd $(srcdir); pwd`; export s
; \
1407 (cd gcc
; $(MAKE
) $(GCC_FLAGS_TO_PASS
) all); \
1412 # Building GCC uses some tools for rebuilding "source" files
1413 # like texinfo, bison/byacc, etc. So we must depend on those.
1415 # While building GCC, it may be necessary to run various target
1416 # programs like the assembler, linker, etc. So we depend on
1419 # In theory, on an SMP all those dependencies can be resolved
1422 .PHONY
: bootstrap bootstrap-lean bootstrap2 bootstrap2-lean bootstrap3 bootstrap3-lean bootstrap4 bootstrap4-lean
1423 bootstrap bootstrap-lean bootstrap2 bootstrap2-lean bootstrap3 bootstrap3-lean bootstrap4 bootstrap4-lean
: all-texinfo all-bison all-byacc all-binutils all-gas all-ld
1424 @r
=`pwd`; export r
; \
1425 s
=`cd $(srcdir); pwd`; export s
; \
1427 echo
"Bootstrapping the compiler"; \
1428 cd gcc
; $(MAKE
) $(GCC_FLAGS_TO_PASS
) $@
1429 @r
=`pwd`; export r
; \
1430 s
=`cd $(srcdir); pwd`; export s
; \
1432 *bootstrap4-lean
) \
1433 msg
="Comparing stage3 and stage4 of the compiler"; \
1434 compare
=compare3-lean
;; \
1435 *bootstrap4
) msg
="Comparing stage3 and stage4 of the compiler"; \
1436 compare
=compare3
;; \
1437 *-lean
) msg
="Comparing stage2 and stage3 of the compiler"; \
1438 compare
=compare-lean
;; \
1439 * ) msg
="Comparing stage2 and stage3 of the compiler"; \
1440 compare
=compare
;; \
1444 cd gcc
; $(MAKE
) $(GCC_FLAGS_TO_PASS
) $$compare
1445 @r
=`pwd`; export r
; \
1446 s
=`cd $(srcdir); pwd` ; export s
; \
1448 echo
"Building runtime libraries"; \
1449 $(MAKE
) $(BASE_FLAGS_TO_PASS
) all
1452 cross
: all-texinfo all-bison all-byacc all-binutils all-gas all-ld
1453 @r
=`pwd`; export r
; \
1454 s
=`cd $(srcdir); pwd`; export s
; \
1456 echo
"Building the C and C++ compiler"; \
1457 cd gcc
; $(MAKE
) $(GCC_FLAGS_TO_PASS
) LANGUAGES
="c c++"
1458 @r
=`pwd`; export r
; \
1459 s
=`cd $(srcdir); pwd` ; export s
; \
1461 echo
"Building runtime libraries"; \
1462 $(MAKE
) $(BASE_FLAGS_TO_PASS
) all LANGUAGES
="c c++"
1466 @if
[ -f .
/gcc
/Makefile
] ; then \
1467 r
=`pwd`; export r
; \
1468 s
=`cd $(srcdir); pwd`; export s
; \
1470 (cd gcc
; $(MAKE
) $(GCC_FLAGS_TO_PASS
) check); \
1477 @if
[ -f .
/gcc
/Makefile
] ; then \
1478 r
=`pwd`; export r
; \
1479 s
=`cd $(srcdir); pwd`; export s
; \
1481 (cd gcc
; $(MAKE
) $(GCC_FLAGS_TO_PASS
) install); \
1486 .PHONY
: install-gcc-cross
1488 @if
[ -f .
/gcc
/Makefile
] ; then \
1489 r
=`pwd`; export r
; \
1490 s
=`cd $(srcdir); pwd`; export s
; \
1492 (cd gcc
; $(MAKE
) $(GCC_FLAGS_TO_PASS
) LANGUAGES
="c c++" install); \
1496 # EXPERIMENTAL STUFF
1497 # This rule is used to install the modules which use FLAGS_TO_PASS.
1498 # To build a target install-X means to cd to X and make install.
1499 .PHONY
: install-dosrel
1500 install-dosrel
: installdirs info
1501 @
dir=`echo $@ | sed -e 's/install-//'`; \
1502 if
[ -f .
/$${dir}/Makefile
] ; then \
1503 r
=`pwd`; export r
; \
1504 s
=`cd $(srcdir); pwd`; export s
; \
1506 (cd
$${dir}; $(MAKE
) $(FLAGS_TO_PASS
) install); \
1511 install-dosrel-fake
:
1514 # This is a list of inter-dependencies among modules.
1517 all-autoconf
: all-m4 all-texinfo
1518 all-automake
: all-m4 all-texinfo
1520 all-bfd
: all-libiberty all-intl
1521 all-binutils
: all-libiberty all-opcodes all-bfd all-flex all-bison all-byacc all-intl
1522 all-bison
: all-texinfo
1526 configure-target-cygmon
: $(ALL_GCC
)
1527 all-target-cygmon
: configure-target-cygmon all-gas all-ld all-gcc all-target-libiberty all-target-newlib all-target-libio all-target-libstub
1529 all-dejagnu
: all-tcl all-expect all-tk
1530 all-diff
: all-libiberty
1532 all-emacs19
: all-bison all-byacc
1534 configure-target-examples
: $(ALL_GCC
)
1535 all-target-examples
: configure-target-examples
1536 all-expect
: all-tcl all-tk
1537 all-fileutils
: all-libiberty
1540 all-flex
: all-libiberty all-bison all-byacc
1541 all-gas
: all-libiberty all-opcodes all-bfd all-intl
1545 all-gcc
: all-bison all-byacc all-binutils all-gas all-ld
1546 all-bootstrap
: all-libiberty all-bison all-byacc all-binutils all-gas all-ld
1547 GDB_TK
= all-tk all-tcl all-itcl all-tix all-libgui
1548 all-gdb
: all-libiberty all-opcodes all-bfd all-mmalloc all-readline all-bison all-byacc all-sim
$(gdbnlmrequirements
) $(GDB_TK
)
1551 configure-target-gperf
: $(ALL_GCC
)
1552 all-target-gperf
: configure-target-gperf all-target-libiberty all-target-libstdc
++
1553 all-gprof
: all-libiberty all-bfd all-opcodes all-intl
1554 all-grep
: all-libiberty
1555 all-grez
: all-libiberty all-bfd all-opcodes
1556 all-gui
: all-gdb all-libproc all-target-librx
1558 all-gzip
: all-libiberty
1559 all-hello
: all-libiberty
1561 all-inet
: all-tcl all-send-pr all-perl
1563 all-ispell
: all-emacs19
1564 all-itcl
: all-tcl all-tk
1565 all-ld
: all-libiberty all-bfd all-opcodes all-bison all-byacc all-flex all-intl
1566 configure-target-libg
++: $(ALL_GCC
) configure-target-librx
1567 all-target-libg
++: configure-target-libg
++ all-gas all-ld all-gcc all-target-libiberty all-target-newlib all-target-libio all-target-librx all-target-libstdc
++
1568 configure-target-libgloss
: $(ALL_GCC
)
1569 all-target-libgloss
: configure-target-libgloss configure-target-newlib
1570 configure-target-libio
: $(ALL_GCC
)
1571 all-target-libio
: configure-target-libio all-gas all-ld all-gcc all-target-libiberty all-target-newlib
1572 check-target-libio
: all-target-libstdc
++
1573 all-libgui
: all-tcl all-tk all-itcl
1575 configure-target-librx
: $(ALL_GCC
) configure-target-newlib
1576 all-target-librx
: configure-target-librx
1577 configure-target-libstdc
++: $(ALL_GCC
)
1578 all-target-libstdc
++: configure-target-libstdc
++ all-gas all-ld all-gcc all-target-libiberty all-target-newlib all-target-libio
1579 configure-target-libstub
: $(ALL_GCC
)
1580 all-target-libstub
: configure-target-libstub
1582 all-target-libf2c
: configure-target-libf2c all-gas all-ld all-gcc all-target-libiberty all-target-newlib
1583 all-target-libchill
: configure-target-libchill all-gas all-ld all-gcc all-target-libiberty all-target-newlib
1584 all-target-libobjc
: configure-target-libobjc all-gas all-ld all-gcc all-target-libiberty all-target-newlib
1585 all-m4
: all-libiberty
1586 all-make
: all-libiberty
1588 configure-target-newlib
: $(ALL_GCC
)
1589 all-target-newlib
: configure-target-newlib all-binutils all-gas all-gcc
1590 all-opcodes
: all-bfd all-libiberty
1591 all-patch
: all-libiberty
1593 all-prms
: all-libiberty
1596 all-recode
: all-libiberty
1597 all-sed
: all-libiberty
1598 all-send-pr
: all-prms
1600 all-sim
: all-libiberty all-bfd all-opcodes all-readline
1601 all-snavigator
: all-tcl all-tk all-itcl all-db all-grep all-flexlm all-libgui
1602 all-tar
: all-libiberty
1604 all-tclX
: all-tcl all-tk
1606 all-texinfo
: all-libiberty
1608 all-tgas
: all-libiberty all-bfd all-opcodes
1610 all-tix
: all-tcl all-tk
1612 all-target-winsup
: all-target-newlib all-target-libiberty all-target-libio configure-target-winsup
1613 configure-target-winsup
: configure-target-newlib
1614 all-uudecode
: all-libiberty
1615 configure-target-libiberty
: $(ALL_GCC
)
1616 all-target-libiberty
: configure-target-libiberty all-gcc all-ld all-target-newlib
1617 all-target
: $(ALL_TARGET_MODULES
)
1618 install-target
: $(INSTALL_TARGET_MODULES
)
1620 ### other supporting targets
1626 installdirs: mkinstalldirs
1627 $(SHELL
) $(srcdir)/mkinstalldirs
$(MAKEDIRS
)
1629 dir.
info: do-install-info
1630 if
[ -f
$(srcdir)/texinfo
/gen-info-dir
] ; then \
1631 $(srcdir)/texinfo
/gen-info-dir
$(infodir) $(srcdir)/texinfo
/dir.info-template
> dir.
info.new
; \
1632 mv
-f
dir.
info.new
dir.
info ; \
1637 @echo
"Building a full distribution of this tree isn't done"
1638 @echo
"via 'make dist'. Check out the etc/ subdirectory"
1642 # Right now this just builds TAGS in each subdirectory. emacs19 has the
1643 # ability to use several tags files at once, so there is probably no need
1644 # to combine them into one big TAGS file (like CVS 1.3 does). We could
1645 # (if we felt like it) have this Makefile write a piece of elisp which
1646 # the user could load to tell emacs19 where all the TAGS files we just
1650 # with the gnu make, this is done automatically.
1652 Makefile
: Makefile.in configure.in
$(host_makefile_frag
) $(target_makefile_frag
) $(gcc_version_trigger
)
1653 $(SHELL
) .
/config.status
1656 # Support for building net releases
1658 # Files in devo used in any net release.
1659 # ChangeLog omitted because it may refer to files which are not in this
1660 # distribution (perhaps it would be better to include it anyway).
1661 DEVO_SUPPORT
= README Makefile.in configure configure.in \
1662 config.guess config.sub config move-if-change \
1663 mpw-README mpw-build.in mpw-config.in mpw-configure mpw-install \
1664 COPYING COPYING.LIB install-sh config-ml.in symlink-tree \
1665 mkinstalldirs ltconfig ltmain.sh missing ylwrap
1667 # Files in devo/etc used in any net release.
1668 # ChangeLog omitted because it may refer to files which are not in this
1669 # distribution (perhaps it would be better to include it anyway).
1670 ETC_SUPPORT
= Makefile.in configure configure.in standards.texi \
1671 make-stds.texi standards.
info*
1673 # When you use `make setup-dirs' or `make taz' you should always redefine
1675 SUPPORT_FILES
= list-of-support-files-for-tool-in-question
1679 taz
: $(DEVO_SUPPORT
) $(SUPPORT_FILES
) \
1680 texinfo
/texinfo.
tex texinfo
/gpl.texinfo texinfo
/lgpl.texinfo
1681 # Take out texinfo from a few places
1682 sed
-e
'/^all\.normal: /s/\all-texinfo //' \
1683 -e
'/^ install-texinfo /d' \
1685 mv
-f tmp Makefile.in
1688 [ -z
"$(CONFIGURE_TARGET_MODULES)" ] \
1689 ||
$(MAKE
) $(CONFIGURE_TARGET_MODULES
) ALL_GCC
="" \
1690 CC_FOR_TARGET
="$(CC)" CXX_FOR_TARGET
="$(CXX)"
1691 # Make links, and run "make diststuff" or "make info" when needed.
1692 rm -rf proto-toplev
; mkdir proto-toplev
1693 set
-e
; dirs
="$(TOOL) $(DEVO_SUPPORT) $(SUPPORT_FILES)" ; \
1694 for d in
$$dirs ; do \
1695 if
[ -d
$$d ]; then \
1696 if
[ ! -f
$$d/Makefile
] ; then true
; \
1697 elif grep
'^diststuff:' $$d/Makefile
>/dev
/null
; then \
1698 (cd
$$d ; $(MAKE
) diststuff
) || exit
1 ; \
1699 elif grep
'^info:' $$d/Makefile
>/dev
/null
; then \
1700 (cd
$$d ; $(MAKE
) info ) || exit
1 ; \
1702 if
[ -d
$$d/proto-
$$d.
dir ]; then \
1703 ln
-s ..
/$$d/proto-
$$d.
dir proto-toplev
/$$d ; \
1705 ln
-s ..
/$$d proto-toplev
/$$d ; \
1707 else ln
-s ..
/$$d proto-toplev
/$$d ; fi
; \
1709 cd etc
; $(MAKE
) info
1712 mkdir proto-toplev
/etc
1713 (cd proto-toplev
/etc
; \
1714 for i in
$(ETC_SUPPORT
); do \
1715 ln
-s ..
/..
/etc
/$$i .
; \
1718 # Take out texinfo from configurable dirs
1719 rm proto-toplev
/configure.in
1720 sed
-e
'/^host_tools=/s/texinfo //' \
1721 <configure.in
>proto-toplev
/configure.in
1723 mkdir proto-toplev
/texinfo
1724 ln
-s ..
/..
/texinfo
/texinfo.
tex proto-toplev
/texinfo
/
1725 ln
-s ..
/..
/texinfo
/gpl.texinfo proto-toplev
/texinfo
/
1726 ln
-s ..
/..
/texinfo
/lgpl.texinfo proto-toplev
/texinfo
/
1727 if
test -r texinfo
/util
/tex3patch
; then \
1728 mkdir proto-toplev
/texinfo
/util
&& \
1729 ln
-s ..
/..
/..
/texinfo
/util
/tex3patch proto-toplev
/texinfo
/util
; \
1731 chmod
-R og
=u . || chmod og
=u
`find . -print`
1732 if grep AM_INIT_AUTOMAKE
$(TOOL
)/configure.in
>/dev
/null
2>&1; then \
1733 ver
=`sed < $(TOOL)/configure.in -n 's/AM_INIT_AUTOMAKE[^,]*, *\([^)]*\))/\1/p'`; \
1735 ver
=`sed <$(TOOL)/Makefile.in -n 's/^VERSION *= *//p'`; \
1737 $(MAKE
) -f Makefile.in do-tar-gz TOOL
=$(TOOL
) VER
=$$ver
1740 echo
"==> Making $(TOOL)-$(VER).tar.gz"
1741 -rm -f
$(TOOL
)-$(VER
)
1742 ln
-s proto-toplev
$(TOOL
)-$(VER
)
1743 tar cfh
$(TOOL
)-$(VER
).
tar $(TOOL
)-$(VER
)
1744 $(GZIPPROG
) -v
-9 $(TOOL
)-$(VER
).
tar
1746 TEXINFO_SUPPORT
= texinfo
/texinfo.
tex texinfo
/gpl.texinfo texinfo
/lgpl.texinfo
1747 DIST_SUPPORT
= $(DEVO_SUPPORT
) $(TEXINFO_SUPPORT
)
1750 GAS_SUPPORT_DIRS
= bfd
include libiberty opcodes intl setup.com makefile.vms
1751 gas.
tar.gz
: $(DIST_SUPPORT
) $(GAS_SUPPORT_DIRS
) gas
1752 $(MAKE
) -f Makefile.in taz TOOL
=gas \
1753 SUPPORT_FILES
="$(GAS_SUPPORT_DIRS)"
1755 # The FSF "binutils" release includes gprof and ld.
1756 .PHONY
: binutils.
tar.gz
1757 BINUTILS_SUPPORT_DIRS
= bfd gas
include libiberty opcodes
ld gprof intl setup.com makefile.vms
1758 binutils.
tar.gz
: $(DIST_SUPPORT
) $(BINUTILS_SUPPORT_DIRS
) binutils
1759 $(MAKE
) -f Makefile.in taz TOOL
=binutils \
1760 SUPPORT_FILES
="$(BINUTILS_SUPPORT_DIRS) makeall.bat configure.bat"
1762 .PHONY
: gas
+binutils.
tar.gz
1763 GASB_SUPPORT_DIRS
= $(GAS_SUPPORT_DIRS
) binutils
ld gprof
1764 gas
+binutils.
tar.gz
: $(DIST_SUPPORT
) $(GASB_SUPPORT_DIRS
) gas
1765 $(MAKE
) -f Makefile.in taz TOOL
=gas \
1766 SUPPORT_FILES
="$(GASB_SUPPORT_DIRS) makeall.bat configure.bat"
1768 .PHONY
: libg
++.
tar.gz
1769 LIBGXX_SUPPORT_DIRS
=include libstdc
++ libio librx libiberty
1770 libg
++.
tar.gz
: $(DIST_SUPPORT
) libg
++
1771 $(MAKE
) -f Makefile.in taz TOOL
=libg
++ \
1772 SUPPORT_FILES
="$(LIBGXX_SUPPORT_DIRS)"
1774 GNATS_SUPPORT_DIRS
=include libiberty send-pr
1775 gnats.
tar.gz
: $(DIST_SUPPORT
) $(GNATS_SUPPORT_DIRS
) gnats
1776 $(MAKE
) -f Makefile.in taz TOOL
=gnats \
1777 SUPPORT_FILES
="$(GNATS_SUPPORT_DIRS)"
1780 GDB_SUPPORT_DIRS
= bfd
include libiberty mmalloc opcodes readline sim utils intl
1781 GDBTK_SUPPORT_DIRS
= `if [ -d tcl -a -d tk ] ; then echo tcl tk ; fi`
1782 gdb.
tar.gz
: $(DIST_SUPPORT
) $(GDB_SUPPORT_DIRS
) gdb
1783 $(MAKE
) -f Makefile.in taz TOOL
=gdb \
1784 SUPPORT_FILES
="$(GDB_SUPPORT_DIRS) $(GDBTK_SUPPORT_DIRS)"
1786 .PHONY
: newlib.
tar.gz
1787 NEWLIB_SUPPORT_DIRS
=libgloss
1788 # taz configures for the sun4 target which won't configure newlib.
1789 # We need newlib configured so that the .info files are made.
1790 # Unfortunately, it is not enough to just configure newlib separately:
1791 # taz will build the .info files but since SUBDIRS won't contain newlib,
1792 # distclean won't be run (leaving Makefile, config.status, and the tmp files
1793 # used in building the .info files, eg: *.def, *.ref).
1794 # The problem isn't solvable however without a lot of extra work because
1795 # target libraries are built in subdir $(target_alias) which gets nuked during
1796 # the make distclean. For now punt on the issue of shipping newlib info files
1797 # with newlib net releases and wait for a day when some native target (sun4?)
1798 # supports newlib (if only minimally).
1799 newlib.
tar.gz
: $(DIST_SUPPORT
) $(NEWLIB_SUPPORT_DIRS
) newlib
1800 $(MAKE
) -f Makefile.in taz TOOL
=newlib \
1801 SUPPORT_FILES
="$(NEWLIB_SUPPORT_DIRS)" \
1802 DEVO_SUPPORT
="$(DEVO_SUPPORT) COPYING.NEWLIB" newlib
1807 # end of Makefile.in