2 # Makefile for directory with subdirs to build.
3 # Copyright (C) 1990, 1991, 1992 Free Software Foundation
5 # This file is free software; you can redistribute it and/or modify
6 # it under the terms of the GNU General Public License as published by
7 # the Free Software Foundation; either version 2 of the License, or
8 # (at your option) any later version.
10 # This program is distributed in the hope that it will be useful,
11 # but WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 # GNU General Public License for more details.
15 # You should have received a copy of the GNU General Public License
16 # along with this program; if not, write to the Free Software
17 # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
24 exec_prefix = $(prefix)
25 bindir = $(exec_prefix)/bin
26 libdir = $(exec_prefix)/lib
29 program_transform_name
=
31 datadir = $(prefix)/lib
32 mandir = $(prefix)/man
33 man1dir = $(mandir)/man1
34 man2dir = $(mandir)/man2
35 man3dir = $(mandir)/man3
36 man4dir = $(mandir)/man4
37 man5dir = $(mandir)/man5
38 man6dir = $(mandir)/man6
39 man7dir = $(mandir)/man7
40 man8dir = $(mandir)/man8
41 man9dir = $(mandir)/man9
42 infodir = $(prefix)/info
43 includedir = $(prefix)/include
44 docdir
= $(datadir)/doc
49 INSTALL_PROGRAM
= $(INSTALL
)
50 INSTALL_DATA
= $(INSTALL
)
59 GCC_FOR_TARGET
= .
/gcc
-B.
/
63 BISON
= `if [ -f $${rootme}/byacc/byacc ] ; \
64 then echo $${rootme}/byacc/byacc ; \
68 LEX
= `if [ -f $${rootme}/flex/flex ] ; \
69 then echo $${rootme}/flex/flex ; \
72 MAKEINFO
= `if [ -f $${rootme}/texinfo/C/makeinfo ] ; \
73 then echo $${rootme}/texinfo/C/makeinfo ; \
74 else echo makeinfo ; fi`
76 # compilers to use to create programs which must be run in the build
79 CXX_FOR_BUILD
= $(CXX
)
81 SUBDIRS
= "this is set via configure, don't edit this"
85 INSTALL_TARGET
= install.
all
91 if [ -f $${rootme}/gcc/Makefile ] ; then \
92 echo $${rootme}/gcc/gcc -B$${rootme}/gcc/; \
94 if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
97 t='$(program_transform_name)'; echo gcc | sed -e '' $$t; \
102 if [ -f $${rootme}/gcc/Makefile ] ; then \
103 echo $${rootme}/gcc/gcc -B$${rootme}/gcc/; \
105 if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
108 t='$(program_transform_name)'; echo gcc | sed -e '' $$t; \
113 if [ -f $${rootme}/gas/Makefile ] ; then \
114 echo $${rootme}/gas/as.new ; \
116 if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
119 t='$(program_transform_name)'; echo as | sed -e '' $$t ; \
124 if [ -f $${rootme}/binutils/Makefile ] ; then \
125 echo $${rootme}/binutils/ar ; \
127 if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
130 t='$(program_transform_name)'; echo ar | sed -e '' $$t ; \
134 RANLIB_FOR_TARGET
= ` \
135 if [ -f $${rootme}/binutils/Makefile ] ; then \
136 echo $${rootme}/binutils/ranlib ; \
138 if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
141 t='$(program_transform_name)'; echo ranlib | sed -e '' $$t ; \
146 if [ -f $${rootme}/binutils/Makefile ] ; then \
147 echo $${rootme}/binutils/nm ; \
149 if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
152 t='$(program_transform_name)'; echo nm | sed -e '' $$t ; \
157 if [ -f $${rootme}/gcc/Makefile ] ; then \
158 if [ -f $${rootme}/newlib/Makefile ] ; then \
159 echo -I$${rootme}/newlib/targ-include -I$${srcroot}/newlib/libc/include -I$${rootme}/gcc/include -nostdinc ; \
161 echo -I$${rootme}/gcc/include ; \
168 #### host and target specific makefile fragments come in here.
171 # Flags to pass down to sub-makes -- please keep these in alphabetical order
174 "AR_FLAGS=$(AR_FLAGS)" \
175 "AR_FOR_TARGET=$(AR_FOR_TARGET)" \
177 "CXXFLAGS=$(CXXFLAGS)" \
178 "CXX_FOR_BUILD=$(CXX_FOR_BUILD)" \
180 "CC_FOR_BUILD=$(CC_FOR_BUILD)" \
182 "GCC_FOR_TARGET=$(GCC_FOR_TARGET)" \
183 "INSTALL=$(INSTALL)" \
184 "INSTALL_DATA=$(INSTALL_DATA)" \
185 "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \
186 "LDFLAGS=$(LDFLAGS)" \
188 "LOADLIBES=$(LOADLIBES)" \
189 "MAKEINFO=$(MAKEINFO)" \
191 "RANLIB_FOR_TARGET=$(RANLIB_FOR_TARGET)" \
192 "exec_prefix=$(exec_prefix)" \
196 # Flags that are concerned with the location of the X11 include files
198 X11_FLAGS_TO_PASS
= \
199 "X11_INCLUDE_FLAGS=$(X11_INCLUDE_FLAGS)" \
200 "X11_LIB_FLAGS=$(X11_LIB_FLAGS)"
202 # Flags to pass down to makes which are built with the target
203 # environment (e.g. libg++, xiberty, newlib). -- keep these in alpha order please
204 TARGET_FLAGS_TO_PASS
= \
205 "AR=$(AR_FOR_TARGET)" \
206 "AR_FLAGS=$(AR_FLAGS)" \
207 "AS=$(AS_FOR_TARGET)" \
209 "CXX=$(CXX_FOR_TARGET)" \
210 "CXX_FOR_BUILD=$(CXX_FOR_BUILD)" \
211 "CXXFLAGS=$(CXXFLAGS)" \
212 "CC=$(CC_FOR_TARGET)" \
213 "CC_FOR_BUILD=$(CC_FOR_BUILD)" \
215 "INSTALL=$(INSTALL)" \
216 "INSTALL_DATA=$(INSTALL_DATA)" \
217 "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \
218 "LDFLAGS=$(LDFLAGS)" \
220 "LOADLIBES=$(LOADLIBES)" \
221 "MAKEINFO=$(MAKEINFO)" \
222 "NM=$(NM_FOR_TARGET)" \
223 "RANLIB=$(RANLIB_FOR_TARGET)" \
224 "XTRAFLAGS=$(XTRAFLAGS)" \
225 "exec_prefix=$(exec_prefix)" \
229 # The first rule in the file had better be this one. Don't put any above it.
232 .PHONY
: all check dvi info install-info
236 @rootme
=`pwd` ; export rootme
; \
237 $(MAKE
) $(FLAGS_TO_PASS
) DO
=$@
"DODIRS=$(SUBDIRS)" subdir_do
239 install-info
: install-info-dirs
force
240 -parent
=`echo $(infodir)|sed -e 's@/[^/]*$$@@'`; \
241 if
[ -d
$$parent ] ; then true
; else mkdir
$$parent ; fi
242 -if
[ -d
$(infodir) ] ; then true
; else mkdir
$(infodir) ; fi
243 @rootme
='pwd' ; export rootme
; $(MAKE
) $(FLAGS_TO_PASS
) DO
=install-info
"DODIRS=$(SUBDIRS)" subdir_do
244 @rootme
='pwd' ; export rootme
; $(MAKE
) $(FLAGS_TO_PASS
) dir.
info install-dir.
info
247 -parent
=`echo $(infodir)|sed -e 's@/[^/]*$$@@'`; \
248 if
[ -d
$$parent ] ; then true
; else mkdir
$$parent ; fi
249 -if
[ -d
$(infodir) ] ; then true
; else mkdir
$(infodir) ; fi
250 $(INSTALL_DATA
) dir.
info $(infodir)/dir.
info
252 all.normal
: all-m4 all-autoconf all-libiberty all-mmalloc all-texinfo \
253 all-byacc all-flex all-opcodes all-bfd all-ld all-gas all-tgas \
254 all-gcc all-binutils all-libg
++ all-readline all-z8ksim all-h8300sim all-gdb \
255 all-make all-rcs all-cvs all-diff all-grep \
256 all-patch all-emacs all-ispell all-etc \
257 all-tcl all-tk all-expect \
259 $(start-sanitize-chill
) \
261 $(end-sanitize-chill
) \
262 all-gprof all-send_pr all-libm all-deja-gnu \
263 all-fileutils all-find all-gawk all-sed all-shellutils \
264 all-textutils all-time all-wdiff
267 all.cross
: all-libiberty all-mmalloc all-gas all-byacc all-flex all-ld \
268 all-opcodes all-z8ksim all-h8300sim all-bfd all-readline \
269 all-gdb all-binutils all-gcc all-newlib \
270 $(start-sanitize-chill
) \
272 $(end-sanitize-chill
) \
275 .PHONY
: clean distclean mostlyclean realclean do_clean
278 -rm -f
*.a TEMP errs core
*.o
*~ \
#* TAGS *.E
280 clean mostlyclean: do_clean
281 @rootme
=`pwd` ; export rootme
; \
282 $(MAKE
) $(FLAGS_TO_PASS
) DO
=$@
"DODIRS=$(SUBDIRS)" subdir_do
284 distclean realclean: do_clean
285 @rootme
=`pwd` ; export rootme
; \
286 $(MAKE
) $(FLAGS_TO_PASS
) DO
=$@
"DODIRS=$(SUBDIRS)" subdir_do
287 -rm -f Makefile config.status
290 @echo
"the uninstall target is not supported in this tree"
292 install: $(INSTALL_TARGET
)
293 -parent
=`echo $(man1dir)|sed -e 's@/[^/]*$$@@'`; \
294 if
[ -d
$$parent ] ; then true
; else mkdir
$$parent ; fi
295 -if
[ -d
$(man1dir) ] ; then true
; else mkdir
$(man1dir) ; fi
297 install.
all: install-no-fixedincludes
298 @if
[ -f .
/gcc
/Makefile
] ; then \
299 rootme
=`pwd` ; export rootme
; \
301 $(MAKE
) $(FLAGS_TO_PASS
) install-headers
) ; \
306 install-no-fixedincludes
: install-dirs gcc-no-fixedincludes \
332 $(start-sanitize-chill
) \
334 $(end-sanitize-chill
) \
344 install-fileutils install-find install-gawk install-m4 install-sed install-shellutils \
345 install-textutils install-time install-wdiff
347 gcc-no-fixedincludes
:
348 @if
[ -f .
/gcc
/Makefile
] ; then \
349 rootme
=`pwd` ; export rootme
; \
351 $(MAKE
) $(FLAGS_TO_PASS
) install install-man \
352 "INSTALL_HEADERS=install-common-headers install-float-h install-limits-h") ; \
357 install.cross
: install-dirs install-libiberty install-mmalloc \
358 install-binutils install-opcodes install-byacc install-flex \
359 install-ld install-gas install-readline \
360 install-glob install-gdb install-mmalloc \
362 $(start-sanitize-chill
) \
364 $(end-sanitize-chill
) \
365 install-gcc install-etc install-deja-gnu
369 @if
[ -f .
/deja-gnu
/Makefile
] ; then \
370 rootme
=`pwd` ; export rootme
; \
371 (cd .
/deja-gnu
; $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
376 install-deja-gnu
: force
377 @if
[ -f .
/deja-gnu
/Makefile
] ; then \
378 rootme
=`pwd` ; export rootme
; \
379 (cd .
/deja-gnu
; $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
386 @if
[ -f .
/autoconf
/Makefile
] ; then \
387 rootme
=`pwd` ; export rootme
; \
388 (cd .
/autoconf
; $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
393 install-autoconf
: force
394 @if
[ -f .
/autoconf
/Makefile
] ; then \
395 rootme
=`pwd` ; export rootme
; \
396 (cd .
/autoconf
; $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
403 @if
[ -f .
/etc
/Makefile
] ; then \
404 rootme
=`pwd` ; export rootme
; \
405 (cd .
/etc
; $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
411 @if
[ -f .
/etc
/Makefile
] ; then \
412 rootme
=`pwd` ; export rootme
; \
413 (cd .
/etc
; $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
420 @if
[ -f .
/libiberty
/Makefile
] ; then \
421 rootme
=`pwd` ; export rootme
; \
423 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
428 install-libiberty
: force
429 @if
[ -f .
/libiberty
/Makefile
] ; then \
430 rootme
=`pwd` ; export rootme
; \
432 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
438 all-xiberty
: all-gcc all-newlib
439 @if
[ -f .
/xiberty
/Makefile
] ; then \
440 rootme
=`pwd` ; export rootme
; \
441 srcroot
=`cd $(srcdir); pwd`; export srcroot
; \
443 $(MAKE
) $(TARGET_FLAGS_TO_PASS
) all) ; \
448 install-xiberty
: force
449 @if
[ -f .
/xiberty
/Makefile
] ; then \
450 rootme
=`pwd` ; export rootme
; \
451 srcroot
=`cd $(srcdir); pwd`; export srcroot
; \
453 $(MAKE
) $(TARGET_FLAGS_TO_PASS
) install) ; \
460 @if
[ -f .
/mmalloc
/Makefile
] ; then \
461 rootme
=`pwd` ; export rootme
; \
463 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
468 install-mmalloc
: force
469 @if
[ -f .
/mmalloc
/Makefile
] ; then \
470 rootme
=`pwd` ; export rootme
; \
472 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
478 all-texinfo
: all-libiberty
479 @if
[ -f .
/texinfo
/Makefile
] ; then \
480 rootme
=`pwd` ; export rootme
; \
482 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
487 install-texinfo
: force
488 @if
[ -f .
/texinfo
/Makefile
] ; then \
489 rootme
=`pwd` ; export rootme
; \
491 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
498 @if
[ -f .
/bfd
/Makefile
] ; then \
499 rootme
=`pwd` ; export rootme
; \
501 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
507 @if
[ -f .
/bfd
/Makefile
] ; then \
508 rootme
=`pwd` ; export rootme
; \
510 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
518 @if
[ -f .
/opcodes
/Makefile
] ; then \
519 rootme
=`pwd` ; export rootme
; \
521 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
526 install-opcodes
: force
527 @if
[ -f .
/opcodes
/Makefile
] ; then \
528 rootme
=`pwd` ; export rootme
; \
530 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
536 all-binutils
: all-opcodes all-libiberty all-bfd all-flex
537 @if
[ -f .
/binutils
/Makefile
] ; then \
538 rootme
=`pwd` ; export rootme
; \
540 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
545 install-binutils
: force
546 @if
[ -f .
/binutils
/Makefile
] ; then \
547 rootme
=`pwd` ; export rootme
; \
549 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
555 all-newlib
: all-binutils all-ld all-gas all-gcc
556 @if
[ -f .
/newlib
/Makefile
] ; then \
557 rootme
=`pwd` ; export rootme
; \
558 srcroot
=`cd $(srcdir); pwd` ; export srcroot
; \
560 $(MAKE
) $(TARGET_FLAGS_TO_PASS
) all) ; \
565 install-newlib
: force
566 @if
[ -f .
/newlib
/Makefile
] ; then \
567 rootme
=`pwd` ; export rootme
; \
568 srcroot
=`cd $(srcdir); pwd` ; export srcroot
; \
570 $(MAKE
) $(TARGET_FLAGS_TO_PASS
) install) ; \
575 ### start-sanitize-chill
577 all-chillrt
: all-binutils all-ld all-gas all-gcc all-newlib
578 @if
[ -f .
/chillrt
/Makefile
] ; then \
579 rootme
=`pwd` ; export rootme
; \
580 srcroot
=`cd $(srcdir); pwd` ; export srcroot
; \
582 $(MAKE
) $(TARGET_FLAGS_TO_PASS
) all) ; \
587 install-chillrt
: force
588 @if
[ -f .
/chillrt
/Makefile
] ; then \
589 rootme
=`pwd` ; export rootme
; \
590 srcroot
=`cd $(srcdir); pwd` ; export srcroot
; \
592 $(MAKE
) $(TARGET_FLAGS_TO_PASS
) install) ; \
596 ### end-sanitize-chill
599 all-gprof
: all-libiberty all-bfd
600 @if
[ -f .
/gprof
/Makefile
] ; then \
601 rootme
=`pwd` ; export rootme
; \
603 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
609 @if
[ -f .
/gprof
/Makefile
] ; then \
610 rootme
=`pwd` ; export rootme
; \
612 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
619 @if
[ -f .
/byacc
/Makefile
] ; then \
620 rootme
=`pwd` ; export rootme
; \
622 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
628 @if
[ -f .
/byacc
/Makefile
] ; then \
629 rootme
=`pwd` ; export rootme
; \
631 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
637 all-flex
: all-libiberty
638 @if
[ -f .
/flex
/Makefile
] ; then \
639 rootme
=`pwd` ; export rootme
; \
641 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
647 @if
[ -f .
/flex
/Makefile
] ; then \
648 rootme
=`pwd` ; export rootme
; \
650 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
655 all-gcc
: all-libiberty all-byacc all-binutils
656 @if
[ -f .
/gcc
/Makefile
] ; then \
657 rootme
=`pwd` ; export rootme
; \
659 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
665 @if
[ -f .
/gcc
/Makefile
] ; then \
666 rootme
=`pwd` ; export rootme
; \
668 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
675 @if
[ -f .
/readline
/Makefile
] ; then \
676 rootme
=`pwd` ; export rootme
; \
678 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
683 install-readline
: force
684 @if
[ -f .
/readline
/Makefile
] ; then \
685 rootme
=`pwd` ; export rootme
; \
687 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
694 @if
[ -f .
/glob
/Makefile
] ; then \
695 rootme
=`pwd` ; export rootme
; \
697 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
703 @if
[ -f .
/glob
/Makefile
] ; then \
704 rootme
=`pwd` ; export rootme
; \
706 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
712 all-gas
: all-libiberty all-opcodes all-bfd
713 @if
[ -f .
/gas
/Makefile
] ; then \
714 rootme
=`pwd` ; export rootme
; \
716 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
722 @if
[ -f .
/gas
/Makefile
] ; then \
723 rootme
=`pwd` ; export rootme
; \
725 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
731 all-tgas
: all-libiberty all-bfd
732 @if
[ -f .
/tgas
/Makefile
] ; then \
733 rootme
=`pwd` ; export rootme
; \
735 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
742 all-ld
: all-libiberty all-bfd all-byacc all-flex
743 @if
[ -f .
/ld/Makefile
] ; then \
744 rootme
=`pwd` ; export rootme
; \
746 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
752 @if
[ -f .
/ld/Makefile
] ; then \
753 rootme
=`pwd` ; export rootme
; \
755 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
761 all-gdb
: all-bfd all-opcodes all-libiberty all-mmalloc all-readline all-glob all-byacc
762 @if
[ -f .
/gdb
/Makefile
] ; then \
763 rootme
=`pwd` ; export rootme
; \
765 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
771 @if
[ -f .
/gdb
/Makefile
] ; then \
772 rootme
=`pwd` ; export rootme
; \
774 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
780 all-make
: all-libiberty
781 @if
[ -f .
/make
/Makefile
] ; then \
782 rootme
=`pwd` ; export rootme
; \
784 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
790 @if
[ -f .
/make
/Makefile
] ; then \
791 rootme
=`pwd` ; export rootme
; \
793 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
800 @if
[ -f .
/diff
/Makefile
] ; then \
801 rootme
=`pwd` ; export rootme
; \
803 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
809 @if
[ -f .
/diff
/Makefile
] ; then \
810 rootme
=`pwd` ; export rootme
; \
812 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
819 @if
[ -f .
/grep
/Makefile
] ; then \
820 rootme
=`pwd` ; export rootme
; \
822 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
828 @if
[ -f .
/grep
/Makefile
] ; then \
829 rootme
=`pwd` ; export rootme
; \
831 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
838 @if
[ -f .
/rcs
/Makefile
] ; then \
839 rootme
=`pwd` ; export rootme
; \
841 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
847 @if
[ -f .
/rcs
/Makefile
] ; then \
848 rootme
=`pwd` ; export rootme
; \
850 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
857 @if
[ -f .
/cvs
/Makefile
] ; then \
858 rootme
=`pwd` ; export rootme
; \
860 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
866 @if
[ -f .
/cvs
/Makefile
] ; then \
867 rootme
=`pwd` ; export rootme
; \
869 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
876 @if
[ -f .
/patch
/Makefile
] ; then \
877 rootme
=`pwd` ; export rootme
; \
879 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
885 @if
[ -f .
/patch
/Makefile
] ; then \
886 rootme
=`pwd` ; export rootme
; \
888 $(MAKE
) $(FLAGS_TO_PASS
) \
890 man1dir=$(man1dir) install) ; \
897 @if
[ -f .
/emacs
/Makefile
] ; then \
898 rootme
=`pwd` ; export rootme
; \
900 $(MAKE
) $(FLAGS_TO_PASS
) $(X11_FLAGS_TO_PASS
) all) ; \
906 @if
[ -f .
/emacs
/Makefile
] ; then \
907 rootme
=`pwd` ; export rootme
; \
909 $(MAKE
) $(FLAGS_TO_PASS
) $(X11_FLAGS_TO_PASS
) install) ; \
915 all-ispell
: all-emacs
916 @if
[ -f .
/ispell
/Makefile
] ; then \
917 rootme
=`pwd` ; export rootme
; \
919 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
924 install-ispell
: force
925 @if
[ -f .
/ispell
/Makefile
] ; then \
926 rootme
=`pwd` ; export rootme
; \
928 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
935 @if
[ -f .
/send_pr
/Makefile
] ; then \
936 rootme
=`pwd` ; export rootme
; \
938 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
943 install-send_pr
: force
944 @if
[ -f .
/send_pr
/Makefile
] ; then \
945 rootme
=`pwd` ; export rootme
; \
947 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
954 @if
[ -f .
/libm
/Makefile
] ; then \
955 rootme
=`pwd` ; export rootme
; \
957 $(MAKE
) $(TARGET_FLAGS_TO_PASS
) all) ; \
963 @if
[ -f .
/libm
/Makefile
] ; then \
964 rootme
=`pwd` ; export rootme
; \
966 $(MAKE
) $(TARGET_FLAGS_TO_PASS
) install) ; \
973 all-libg
++: all-gas all-ld all-gcc all-xiberty all-newlib
974 @if
[ -f .
/libg
++/Makefile
] ; then \
975 rootme
=`pwd` ; export rootme
; \
976 srcroot
=`cd $(srcdir); pwd` ; export srcroot
; \
978 $(MAKE
) $(TARGET_FLAGS_TO_PASS
) all) ; \
983 install-libg
++: force
984 @if
[ -f .
/libg
++/Makefile
] ; then \
985 rootme
=`pwd` ; export rootme
; \
986 srcroot
=`cd $(srcdir); pwd` ; export srcroot
; \
988 $(MAKE
) $(TARGET_FLAGS_TO_PASS
) install) ; \
994 @if
[ -f .
/tcl
/Makefile
] ; then \
995 rootme
=`pwd` ; export rootme
; \
996 srcroot
=`cd $(srcdir); pwd`; export srcroot
; \
998 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
1004 @if
[ -f .
/tcl
/Makefile
] ; then \
1005 rootme
=`pwd` ; export rootme
; \
1006 srcroot
=`cd $(srcdir); pwd`; export srcroot
; \
1008 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
1016 @if
[ -f .
/tk
/Makefile
] ; then \
1017 rootme
=`pwd` ; export rootme
; \
1018 srcroot
=`cd $(srcdir); pwd`; export srcroot
; \
1020 $(MAKE
) $(FLAGS_TO_PASS
) $(X11_FLAGS_TO_PASS
) all) ; \
1026 @if
[ -f .
/tk
/Makefile
] ; then \
1027 rootme
=`pwd` ; export rootme
; \
1028 srcroot
=`cd $(srcdir); pwd`; export srcroot
; \
1030 $(MAKE
) $(FLAGS_TO_PASS
) $(X11_FLAGS_TO_PASS
) install) ; \
1037 @if
[ -f .
/expect
/Makefile
] ; then \
1038 rootme
=`pwd` ; export rootme
; \
1039 srcroot
=`cd $(srcdir); pwd`; export srcroot
; \
1041 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
1046 install-expect
: force
1047 @if
[ -f .
/expect
/Makefile
] ; then \
1048 rootme
=`pwd` ; export rootme
; \
1049 srcroot
=`cd $(srcdir); pwd`; export srcroot
; \
1051 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
1058 @if
[ -f .
/z8ksim
/Makefile
] ; then \
1059 rootme
=`pwd` ; export rootme
; \
1061 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
1066 install-z8ksim
: force
1067 @if
[ -f .
/z8ksim
/Makefile
] ; then \
1068 rootme
=`pwd` ; export rootme
; \
1070 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
1076 all-h8300sim
: all-bfd
1077 @if
[ -f .
/h8300sim
/Makefile
] ; then \
1078 rootme
=`pwd` ; export rootme
; \
1080 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
1085 install-h8300sim
: force
1086 @if
[ -f .
/h8300sim
/Makefile
] ; then \
1087 rootme
=`pwd` ; export rootme
; \
1089 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
1096 all-fileutils
: force
1097 @if
[ -f .
/fileutils
/Makefile
] ; then \
1098 rootme
=`pwd` ; export rootme
; \
1099 (cd .
/fileutils
; $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
1104 install-fileutils
: force
1105 @if
[ -f .
/fileutils
/Makefile
] ; then \
1106 rootme
=`pwd` ; export rootme
; \
1107 (cd .
/fileutils
; $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
1114 @if
[ -f .
/find
/Makefile
] ; then \
1115 rootme
=`pwd` ; export rootme
; \
1116 (cd .
/find
; $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
1122 @if
[ -f .
/find
/Makefile
] ; then \
1123 rootme
=`pwd` ; export rootme
; \
1124 (cd .
/find
; $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
1131 @if
[ -f .
/gawk
/Makefile
] ; then \
1132 rootme
=`pwd` ; export rootme
; \
1133 (cd .
/gawk
; $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
1139 @if
[ -f .
/gawk
/Makefile
] ; then \
1140 rootme
=`pwd` ; export rootme
; \
1141 (cd .
/gawk
; $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
1147 all-m4
: all-libiberty
1148 @if
[ -f .
/m4
/Makefile
] ; then \
1149 rootme
=`pwd` ; export rootme
; \
1150 (cd .
/m4
; $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
1156 @if
[ -f .
/m4
/Makefile
] ; then \
1157 rootme
=`pwd` ; export rootme
; \
1158 (cd .
/m4
; $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
1165 @if
[ -f .
/sed
/Makefile
] ; then \
1166 rootme
=`pwd` ; export rootme
; \
1167 (cd .
/sed
; $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
1173 @if
[ -f .
/sed
/Makefile
] ; then \
1174 rootme
=`pwd` ; export rootme
; \
1175 (cd .
/sed
; $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
1182 @if
[ -f .
/time
/Makefile
] ; then \
1183 rootme
=`pwd` ; export rootme
; \
1184 (cd .
/time
; $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
1190 @if
[ -f .
/time
/Makefile
] ; then \
1191 rootme
=`pwd` ; export rootme
; \
1192 (cd .
/time
; $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
1199 @if
[ -f .
/wdiff
/Makefile
] ; then \
1200 rootme
=`pwd` ; export rootme
; \
1201 (cd .
/wdiff
; $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
1206 install-wdiff
: force
1207 @if
[ -f .
/wdiff
/Makefile
] ; then \
1208 rootme
=`pwd` ; export rootme
; \
1209 (cd .
/wdiff
; $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
1215 all-shellutils
: force
1216 @if
[ -f .
/shellutils
/Makefile
] ; then \
1217 rootme
=`pwd` ; export rootme
; \
1218 (cd .
/shellutils
; $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
1223 install-shellutils
: force
1224 @if
[ -f .
/shellutils
/Makefile
] ; then \
1225 rootme
=`pwd` ; export rootme
; \
1226 (cd .
/shellutils
; $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
1232 all-textutils
: force
1233 @if
[ -f .
/textutils
/Makefile
] ; then \
1234 rootme
=`pwd` ; export rootme
; \
1235 (cd .
/textutils
; $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
1240 install-textutils
: force
1241 @if
[ -f .
/textutils
/Makefile
] ; then \
1242 rootme
=`pwd` ; export rootme
; \
1243 (cd .
/textutils
; $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
1250 ### other supporting targets
1253 ### start-sanitize-chill
1255 ### WARNING: THIS IS VERY UGLY AND I DID NOT DO THIS WILLINGLY
1257 ### if you change the code for libg++ et al, also change the
1258 ### code for chillrt
1260 ### end-sanitize-chill
1261 @for i in
$(DODIRS
); do \
1262 if
[ -f .
/$$i/localenv
] ||
[ -f .
/$$i/Makefile
] ; then \
1264 libg
++ | xiberty | newlib
) \
1265 if
(rootme
=`pwd` ; export rootme
; \
1266 srcroot
=`cd $(srcdir); pwd` ; export srcroot
; \
1268 $(MAKE
) $(TARGET_FLAGS_TO_PASS
) $(DO
)) ; then true
; \
1271 $(start-sanitize-chill
) \
1273 if
(rootme
=`pwd` ; export rootme
; \
1274 srcroot
=`cd $(srcdir); pwd` ; export srcroot
; \
1276 $(MAKE
) $(TARGET_FLAGS_TO_PASS
) $(DO
)) ; then true
; \
1279 $(end-sanitize-chill
) \
1281 if
(rootme
=`pwd` ; export rootme
; \
1283 $(MAKE
) $(FLAGS_TO_PASS
) $(DO
)) ; then true
; \
1290 # The "else true" stuff is for Ultrix; the shell returns the exit code
1291 # of the "if" command, if no commands are run in the "then" or "else" part,
1292 # causing Make to quit.
1316 for i in
$(MAKEDIRS
) ; do \
1317 echo Making
$$i...
; \
1318 parent
=`echo $$i|sed -e 's@/[^/]*$$@@'`; \
1319 if
[ -d
$$parent ] ; then true
; else mkdir
$$parent ; fi
; \
1320 if
[ ! -d
$$i ] ; then \
1321 if mkdir
$$i ; then \
1332 if
[ -d
$(prefix) ] ; then true
; else mkdir
$(prefix) ; fi
1335 $(srcdir)/texinfo
/gen-info-dir
$(infodir) $(srcdir)/texinfo
/dir.info-template
> dir.
info.new
1336 mv
-f
dir.
info.new
dir.
info
1339 @echo
"Building a full distribution of this tree isn't done"
1340 @echo
"via 'make dist'. Check out the etc/ subdirectory"
1349 @for i in
$(SUBDIRS
); \
1353 wd
=`basename $$pwd`; \
1354 for j in
`$(MAKE) ls`; \
1362 # with the gnu make, this is done automatically.
1364 Makefile
: $(srcdir)/Makefile.in
$(host_makefile_frag
) $(target_makefile_frag
)
1365 $(SHELL
) .
/config.status
1368 # Build GDB distributions that contain BFD, Include, Libiberty, Readline, etc
1370 DEVO_SUPPORT
= README cfg-paper.texi Makefile.in configure configure.in \
1371 config.sub config configure.man configure.texi move-if-change \
1373 GDB_SUPPORT_DIRS
= bfd
include libiberty mmalloc opcodes readline glob
1374 GDB_SUPPORT_FILES
= $(GDB_SUPPORT_DIRS
) texinfo
/fsf
/texinfo.
tex
1379 .
/configure
-rm sun4
1380 chmod og
=u
`find $(DEVO_SUPPORT) $(GDB_SUPPORT_FILES) -print`
1382 gdb.
tar.Z
: setup-dirs
1383 (cd gdb
; $(MAKE
) -f Makefile.in make-proto-gdb.
dir)
1384 $(MAKE
) $(MFLAGS
) -f Makefile.in make-gdb.
tar.Z
1386 make-gdb.
tar.Z
: $(DEVO_SUPPORT
) $(GDB_SUPPORT_DIRS
) gdb texinfo
/fsf
/texinfo.
tex
1387 rm -rf proto-toplev
; mkdir proto-toplev
1388 ln
-s ..
/gdb
/proto-gdb.
dir proto-toplev
/gdb
1389 (cd proto-toplev
; for i in
$(DEVO_SUPPORT
) $(GDB_SUPPORT_DIRS
); do \
1392 # Put only one copy (four hard links) of COPYING in the tar file.
1393 rm proto-toplev
/bfd
/COPYING
1394 ln proto-toplev
/gdb
/COPYING proto-toplev
/bfd
/COPYING
1395 rm proto-toplev
/include/COPYING
1396 ln proto-toplev
/gdb
/COPYING proto-toplev
/include/COPYING
1397 rm proto-toplev
/readline
/COPYING
1398 ln proto-toplev
/gdb
/COPYING proto-toplev
/readline
/COPYING
1399 # Take out texinfo from configurable dirs
1400 rm proto-toplev
/configure.in
1401 sed
'/^configdirs=/s/texinfo //' <configure.in
>proto-toplev
/configure.in
1402 # Take out glob from buildable dirs
1403 rm proto-toplev
/Makefile.in
1405 sed
-e
'/^SUBDIRS =/s/glob //' \
1406 -e
'/^all\.normal: /s/\all-texinfo //' \
1407 -e
'/^clean: /s/clean-texinfo //' \
1408 -e
'/^install\.all: /s/install-texinfo //' \
1409 <Makefile.in
>proto-toplev
/Makefile.in
1411 mkdir proto-toplev
/texinfo
1412 mkdir proto-toplev
/texinfo
/fsf
1413 ln
-s ..
/..
/..
/texinfo
/fsf
/texinfo.
tex proto-toplev
/texinfo
/fsf
/
1414 chmod og
=u
`find proto-toplev -print`
1415 (VER
=`sed <gdb/Makefile.in -n 's/VERSION = //p'`; \
1416 echo
"==> Making gdb-$$VER.tar.Z"; \
1417 ln
-s proto-toplev gdb-
$$VER; \
1418 tar cfh
- gdb-
$$VER \
1419 | compress
-v
>gdb-
$$VER.
tar.Z
)
1422 # end of Makefile.in