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 datadir = $(prefix)/lib
30 mandir = $(prefix)/man
31 man1dir = $(mandir)/man1
32 man2dir = $(mandir)/man2
33 man3dir = $(mandir)/man3
34 man4dir = $(mandir)/man4
35 man5dir = $(mandir)/man5
36 man6dir = $(mandir)/man6
37 man7dir = $(mandir)/man7
38 man8dir = $(mandir)/man8
39 man9dir = $(mandir)/man9
40 infodir = $(prefix)/info
41 includedir = $(prefix)/include
42 docdir
= $(datadir)/doc
47 INSTALL_PROGRAM
= $(INSTALL
)
48 INSTALL_DATA
= $(INSTALL
)
55 BISON
= `if [ -d $${rootme}/bison ] ; \
56 then echo $${rootme}/bison/bison -L $${rootme}/bison/ -y ; \
57 else echo bison -y ; fi`
59 LEX
= `if [ -d $${rootme}/flex ] ; \
60 then echo $${rootme}/flex/flex -S$${rootme}/flex/flex.skel ; \
63 MAKEINFO
= `if [ -d $${rootme}/texinfo/C ] ; \
64 then echo $${rootme}/texinfo/C/makeinfo ; \
65 else echo makeinfo ; fi`
67 SUBDIRS
= libiberty mmalloc glob readline bfd gdb binutils
ld gas gcc libg
++ libgcc clib newlib
71 INSTALL_TARGET
= install.
all
76 GXX
= `if [ -d $${rootme}/gcc ] ; \
77 then echo $${rootme}/gcc/gcc -B$${rootme}/gcc/ ; \
80 XTRAFLAGS
= `if [ -d $${rootme}/gcc ] ; \
81 then echo -I$${rootme}/gcc/include ; \
84 #### host and target specific makefile fragments come in here.
89 "exec_prefix=$(exec_prefix)" \
90 "tooldir=$(tooldir)" \
92 "AR_FLAGS=$(AR_FLAGS)" \
96 "LOADLIBES=$(LOADLIBES)" \
97 "LDFLAGS=$(LDFLAGS)" \
100 "MAKEINFO=$(MAKEINFO)" \
101 "INSTALL=$(INSTALL)" \
102 "INSTALL_DATA=$(INSTALL_DATA)" \
103 "INSTALL_PROGRAM=$(INSTALL_PROGRAM)"
105 .PHONY
: all info install-info clean-info
110 info: cfg-paper.
info configure.
info standards.
info
111 @rootme
=`pwd` ; export rootme
; $(MAKE
) subdir_do DO
=info "DODIRS=$(SUBDIRS)" $(FLAGS_TO_PASS
)
113 # Note libg++ has to be handled specially (we can't compile it with CC=cc).
115 @rootme
=`pwd` ; export rootme
; $(MAKE
) subdir_do DO
=check \
116 "DODIRS=`echo $(SUBDIRS) | sed -e \"s/libg\+\+//\"" $(FLAGS_TO_PASS
)
117 @rootme
=`pwd` ; export rootme
; $(MAKE
) subdir_do DO
=check \
118 "DODIRS=libg++" $(FLAGS_TO_PASS
) "CC=${GXX}" "XTRAFLAGS=${XTRAFLAGS}"
121 @
$(MAKE
) subdir_do DO
=clean-info
"DODIRS=$(SUBDIRS)"
124 cfg-paper.
info: cfg-paper.texi
125 rootme
=`pwd` ; export rootme
; $(MAKEINFO
) -o cfg-paper.
info $(srcdir)/cfg-paper.texi
127 configure.
info: configure.texi
128 rootme
=`pwd` ; export rootme
; $(MAKEINFO
) -o configure.
info $(srcdir)/configure.texi
130 standards.
info: standards.texi
131 rootme
=`pwd` ; export rootme
; $(MAKEINFO
) -o standards.
info $(srcdir)/standards.texi
133 install-info
: install-info-dirs
force
134 [ -d
$(infodir) ] || mkdir
$(infodir)
135 @
$(MAKE
) subdir_do DO
=install-info
"DODIRS=$(SUBDIRS)"
136 $(INSTALL_DATA
) cfg-paper.
info $(infodir)/cfg-paper.
info
137 $(INSTALL_DATA
) configure.
info $(infodir)/configure.
info
138 $(INSTALL_DATA
) standards.
info $(infodir)/standards.
info
139 @
$(MAKE
) dir.
info install-dir.
info
142 $(INSTALL_DATA
) dir.
info $(infodir)/dir.
info
144 all.normal
: all-autoconf all-libiberty all-mmalloc all-texinfo \
145 all-bison all-byacc all-flex all-bfd all-ld all-gas all-gcc \
146 all-binutils all-libg
++ all-readline all-gdb \
147 all-make all-rcs all-cvs all-diff all-grep \
148 all-patch all-emacs all-ispell \
149 all-newlib all-gprof all-send_pr
151 all.cross
: all-libiberty all-mmalloc all-gas all-bison all-ld \
152 all-bfd all-libgcc all-readline all-gdb
153 # $(MAKE) subdir_do DO=all "DODIRS=$(SUBDIRS) $(OTHERS)"
155 clean: clean-autoconf clean-libiberty clean-mmalloc clean-texinfo \
156 clean-bfd clean-newlib clean-binutils clean-flex \
157 clean-bison clean-byacc clean-ld clean-gas \
158 clean-gcc clean-libgcc clean-readline clean-glob clean-gdb \
159 clean-make clean-diff clean-grep clean-rcs \
160 clean-cvs clean-patch clean-emacs clean-ispell \
161 clean-libg
++ clean-gprof clean-send_pr
162 -rm -rf
*.a TEMP errs core
*.o
*~ \
#* TAGS *.E
167 install: $(INSTALL_TARGET
) $(srcdir)/configure.man
168 $(INSTALL_DATA
) $(srcdir)/configure.man
$(man1dir)/configure
.1
171 install.
all: install-dirs install-autoconf install-libiberty \
172 install-mmalloc install-texinfo install-bfd install-binutils \
173 install-bison install-byacc install-flex install-ld \
174 install-gas install-gcc install-gprof install-libgcc \
175 install-readline install-glob install-gdb install-make \
176 install-cvs install-patch install-emacs install-ispell \
177 install-libg
++ install-newlib \
180 install.cross
: install-dirs install-libiberty install-mmalloc \
181 install-binutils install-bison install-byacc install-flex \
182 install-ld install-gas install-libgcc install-readline \
183 install-glob install-gdb install-mmalloc install-gprof
187 @if
[ -d .
/autoconf
] ; then \
188 rootme
=`pwd` ; export rootme
; \
190 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
195 clean-autoconf
: force
196 @if
[ -d .
/autoconf
] ; then \
197 rootme
=`pwd` ; export rootme
; \
199 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
204 install-autoconf
: force
205 @if
[ -d .
/autoconf
] ; then \
206 rootme
=`pwd` ; export rootme
; \
208 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
215 @if
[ -d .
/libiberty
] ; then \
216 rootme
=`pwd` ; export rootme
; \
218 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
223 clean-libiberty
: force
224 @if
[ -d .
/libiberty
] ; then \
225 rootme
=`pwd` ; export rootme
; \
227 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
232 install-libiberty
: force
233 @if
[ -d .
/libiberty
] ; then \
234 rootme
=`pwd` ; export rootme
; \
236 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
243 @if
[ -d .
/mmalloc
] ; then \
244 rootme
=`pwd` ; export rootme
; \
246 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
252 @if
[ -d .
/mmalloc
] ; then \
253 rootme
=`pwd` ; export rootme
; \
255 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
260 install-mmalloc
: force
261 @if
[ -d .
/mmalloc
] ; then \
262 rootme
=`pwd` ; export rootme
; \
264 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
270 all-texinfo
: all-libiberty
271 @if
[ -d .
/texinfo
] ; then \
272 rootme
=`pwd` ; export rootme
; \
273 rootme
=`pwd` ; export rootme
; \
275 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
281 @if
[ -d .
/texinfo
] ; then \
282 rootme
=`pwd` ; export rootme
; \
284 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
289 install-texinfo
: force
290 @if
[ -d .
/texinfo
] ; then \
291 rootme
=`pwd` ; export rootme
; \
293 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
300 @if
[ -d .
/bfd
] ; then \
301 rootme
=`pwd` ; export rootme
; \
303 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
309 @if
[ -d .
/bfd
] ; then \
310 rootme
=`pwd` ; export rootme
; \
312 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
318 @if
[ -d .
/bfd
] ; then \
319 rootme
=`pwd` ; export rootme
; \
321 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
327 all-binutils
: all-libiberty all-bfd all-flex
328 @if
[ -d .
/binutils
] ; then \
329 rootme
=`pwd` ; export rootme
; \
331 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
336 clean-binutils
: force
337 @if
[ -d .
/binutils
] ; then \
338 rootme
=`pwd` ; export rootme
; \
340 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
345 install-binutils
: force
346 @if
[ -d .
/binutils
] ; then \
347 rootme
=`pwd` ; export rootme
; \
349 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
356 @if
[ -d .
/newlib
] ; then \
357 rootme
=`pwd` ; export rootme
; \
359 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
365 @if
[ -d .
/newlib
] ; then \
366 rootme
=`pwd` ; export rootme
; \
368 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
373 install-newlib
: force
374 @if
[ -d .
/newlib
] ; then \
375 rootme
=`pwd` ; export rootme
; \
377 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
383 all-gprof
: all-libiberty all-bfd
384 @if
[ -d .
/gprof
] ; then \
386 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
392 @if
[ -d
$(unsubdir
)/gprof
] ; then \
393 (cd
$(unsubdir
)/gprof
$(subdir
); \
394 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
400 @if
[ -d
$(unsubdir
)/gprof
] ; then \
401 (cd
$(unsubdir
)/gprof
$(subdir
); \
402 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
409 @if
[ -d .
/byacc
] ; then \
410 rootme
=`pwd` ; export rootme
; \
412 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
418 @if
[ -d .
/byacc
] ; then \
419 rootme
=`pwd` ; export rootme
; \
421 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
427 @if
[ -d .
/byacc
] ; then \
428 rootme
=`pwd` ; export rootme
; \
430 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
436 all-bison
: all-libiberty
437 @if
[ -d .
/bison
] ; then \
438 rootme
=`pwd` ; export rootme
; \
440 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
446 @if
[ -d .
/bison
] ; then \
447 rootme
=`pwd` ; export rootme
; \
449 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
455 @if
[ -d .
/bison
] ; then \
456 rootme
=`pwd` ; export rootme
; \
458 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
464 all-flex
: all-libiberty
465 @if
[ -d .
/flex
] ; then \
466 rootme
=`pwd` ; export rootme
; \
468 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
474 @if
[ -d .
/flex
] ; then \
475 rootme
=`pwd` ; export rootme
; \
477 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
483 @if
[ -d .
/flex
] ; then \
484 rootme
=`pwd` ; export rootme
; \
486 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
491 all-gcc
: all-libiberty all-bison
492 @if
[ -d .
/gcc
] ; then \
493 rootme
=`pwd` ; export rootme
; \
495 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
501 @if
[ -d .
/gcc
] ; then \
502 rootme
=`pwd` ; export rootme
; \
504 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
510 @if
[ -d .
/gcc
] ; then \
511 rootme
=`pwd` ; export rootme
; \
513 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
520 @if
[ -d .
/readline
] ; then \
521 rootme
=`pwd` ; export rootme
; \
523 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
528 clean-readline
: force
529 @if
[ -d .
/readline
] ; then \
530 rootme
=`pwd` ; export rootme
; \
532 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
537 install-readline
: force
538 @if
[ -d .
/readline
] ; then \
539 rootme
=`pwd` ; export rootme
; \
541 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
548 @if
[ -d .
/glob
] ; then \
549 rootme
=`pwd` ; export rootme
; \
551 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
557 @if
[ -d .
/glob
] ; then \
558 rootme
=`pwd` ; export rootme
; \
560 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
566 @if
[ -d .
/glob
] ; then \
567 rootme
=`pwd` ; export rootme
; \
569 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
575 all-gas
: all-libiberty all-bfd
576 @if
[ -d .
/gas
] ; then \
577 rootme
=`pwd` ; export rootme
; \
579 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
585 @if
[ -d .
/gas
] ; then \
586 rootme
=`pwd` ; export rootme
; \
588 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
594 @if
[ -d .
/gas
] ; then \
595 rootme
=`pwd` ; export rootme
; \
597 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
603 all-ld
: all-libiberty all-bfd all-bison all-flex
604 @if
[ -d .
/ld ] ; then \
605 rootme
=`pwd` ; export rootme
; \
607 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
613 @if
[ -d .
/ld ] ; then \
614 rootme
=`pwd` ; export rootme
; \
616 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
622 @if
[ -d .
/ld ] ; then \
623 rootme
=`pwd` ; export rootme
; \
625 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
630 ### libgcc (and libgcc1)
631 all-libgcc1
: all-gas all-binutils
632 @if
[ -d .
/libgcc
] ; then \
633 rootme
=`pwd` ; export rootme
; \
635 $(MAKE
) $(FLAGS_TO_PASS
) libgcc1.a
) ; \
641 @if
[ -d .
/libgcc
] ; then \
642 rootme
=`pwd` ; export rootme
; \
644 $(MAKE
) $(FLAGS_TO_PASS
) clean-libgcc1
) ; \
649 install-libgcc1
: force
650 echo libgcc1 is a component
, not an installable target
652 all-libgcc
: all-gas all-gcc all-binutils
654 @if
[ -d .
/libgcc
] ; then \
655 rootme
=`pwd` ; export rootme
; \
657 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
663 @if
[ -d .
/libgcc
] ; then \
664 rootme
=`pwd` ; export rootme
; \
666 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
671 install-libgcc
: force
672 @if
[ -d .
/libgcc
] ; then \
673 rootme
=`pwd` ; export rootme
; \
675 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
681 all-gdb
: all-bfd all-libiberty all-mmalloc all-readline all-glob all-bison
682 @if
[ -d .
/gdb
] ; then \
683 rootme
=`pwd` ; export rootme
; \
685 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
691 @if
[ -d .
/gdb
] ; then \
692 rootme
=`pwd` ; export rootme
; \
694 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
700 @if
[ -d .
/gdb
] ; then \
701 rootme
=`pwd` ; export rootme
; \
703 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
709 all-make
: all-libiberty
710 @if
[ -d .
/make
] ; then \
711 rootme
=`pwd` ; export rootme
; \
713 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
719 @if
[ -d .
/make
] ; then \
720 rootme
=`pwd` ; export rootme
; \
722 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
728 @if
[ -d .
/make
] ; then \
729 rootme
=`pwd` ; export rootme
; \
731 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
738 @if
[ -d .
/diff
] ; then \
739 rootme
=`pwd` ; export rootme
; \
741 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
747 @if
[ -d .
/diff
] ; then \
748 rootme
=`pwd` ; export rootme
; \
750 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
756 @if
[ -d .
/diff
] ; then \
757 rootme
=`pwd` ; export rootme
; \
759 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
766 @if
[ -d .
/grep
] ; then \
767 rootme
=`pwd` ; export rootme
; \
769 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
775 @if
[ -d .
/grep
] ; then \
776 rootme
=`pwd` ; export rootme
; \
778 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
784 @if
[ -d .
/grep
] ; then \
785 rootme
=`pwd` ; export rootme
; \
787 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
794 @if
[ -d .
/rcs
] ; then \
795 rootme
=`pwd` ; export rootme
; \
797 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
803 @if
[ -d .
/rcs
] ; then \
804 rootme
=`pwd` ; export rootme
; \
806 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
812 @if
[ -d .
/rcs
] ; then \
813 rootme
=`pwd` ; export rootme
; \
815 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
822 @if
[ -d .
/cvs
] ; then \
823 rootme
=`pwd` ; export rootme
; \
825 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
831 @if
[ -d .
/cvs
] ; then \
832 rootme
=`pwd` ; export rootme
; \
834 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
840 @if
[ -d .
/cvs
] ; then \
841 rootme
=`pwd` ; export rootme
; \
843 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
850 @if
[ -d .
/patch
] ; then \
851 rootme
=`pwd` ; export rootme
; \
853 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
859 @if
[ -d .
/patch
] ; then \
860 rootme
=`pwd` ; export rootme
; \
862 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
868 @if
[ -d .
/patch
] ; then \
869 rootme
=`pwd` ; export rootme
; \
871 $(MAKE
) $(FLAGS_TO_PASS
) \
873 man1dir=$(man1dir) install) ; \
880 @if
[ -d .
/emacs
] ; then \
881 rootme
=`pwd` ; export rootme
; \
883 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
889 @if
[ -d .
/emacs
] ; then \
890 rootme
=`pwd` ; export rootme
; \
892 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
898 @if
[ -d .
/emacs
] ; then \
899 rootme
=`pwd` ; export rootme
; \
901 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
907 all-ispell
: all-emacs
908 @if
[ -d .
/ispell
] ; then \
909 rootme
=`pwd` ; export rootme
; \
911 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
917 @if
[ -d .
/ispell
] ; then \
918 rootme
=`pwd` ; export rootme
; \
920 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
925 install-ispell
: force
926 @if
[ -d .
/ispell
] ; then \
927 rootme
=`pwd` ; export rootme
; \
929 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
936 @if
[ -d .
/send_pr
] ; then \
937 rootme
=`pwd` ; export rootme
; \
939 $(MAKE
) $(FLAGS_TO_PASS
) all) ; \
945 @if
[ -d .
/send_pr
] ; then \
946 rootme
=`pwd` ; export rootme
; \
948 $(MAKE
) $(FLAGS_TO_PASS
) clean) ; \
953 install-send_pr
: force
954 @if
[ -d .
/send_pr
] ; then \
955 rootme
=`pwd` ; export rootme
; \
957 $(MAKE
) $(FLAGS_TO_PASS
) install) ; \
964 all-libg
++: all-gas all-ld all-gcc
965 @if
[ -d .
/libg
++ ] ; then \
966 rootme
=`pwd` ; export rootme
; \
968 $(MAKE
) $(FLAGS_TO_PASS
) "CC=${GXX}" all) ; \
974 @if
[ -d .
/libg
++ ] ; then \
975 rootme
=`pwd` ; export rootme
; \
977 $(MAKE
) $(FLAGS_TO_PASS
) "CC=${GXX}" clean) ; \
982 install-libg
++: force
983 @if
[ -d .
/libg
++ ] ; then \
984 rootme
=`pwd` ; export rootme
; \
986 $(MAKE
) $(FLAGS_TO_PASS
) "CC=${GXX}" install) ; \
991 ### other supporting targets
992 # this is a bad hack.
993 all.xclib
: all.normal
994 if
[ -d clib
] ; then \
995 (cd clib
; $(MAKE
) $(FLAGS_TO_PASS
)) ; \
999 @for i in
$(DODIRS
); do \
1000 if
[ -f .
/$$i/localenv
] ; then \
1001 if
(rootme
=`pwd` ; export rootme
; cd .
/$$i; \
1002 $(MAKE
) $(FLAGS_TO_PASS
) $(DO
)) ; then true
; \
1003 else exit
1 ; fi
; \
1004 else if
[ -d .
/$$i ] ; then \
1005 if
(rootme
=`pwd` ; export rootme
; cd .
/$$i; \
1006 $(MAKE
) $(FLAGS_TO_PASS
) $(DO
)) ; then true
; \
1007 else exit
1 ; fi
; \
1012 # The "else true" stuff is for Ultrix; the shell returns the exit code
1013 # of the "if" command, if no commands are run in the "then" or "else" part,
1014 # causing Make to quit.
1037 for i in
$(MAKEDIRS
) ; do \
1038 echo Making
$$i...
; \
1039 [ -d
$$i ] || mkdir
$$i || exit
1 ; \
1047 if
[ -d
$(prefix) ] ; then true
; else mkdir
$(prefix) ; fi
1048 if
[ -d
$(datadir) ] ; then true
; else mkdir
$(datadir) ; fi
1049 if
[ -d
$(infodir) ] ; then true
; else mkdir
$(infodir) ; fi
1052 $(srcdir)/texinfo
/gen-info-dir
$(infodir) > dir.
info.new
1053 mv
-f
dir.
info.new
dir.
info
1062 @for i in
$(SUBDIRS
); \
1066 wd
=`basename $$pwd`; \
1067 for j in
`$(MAKE) ls`; \
1075 # with the gnu make, this is done automatically.
1077 Makefile
: $(srcdir)/Makefile.in
$(host_makefile_frag
) $(target_makefile_frag
)
1078 $(SHELL
) .
/config.status
1081 # Build GDB distributions that contain BFD, Include, Libiberty, Readline, etc
1083 DEVO_SUPPORT
= README cfg-paper.texi Makefile.in configure configure.in \
1084 config.sub config configure.man
1085 GDB_SUPPORT_DIRS
= bfd
include libiberty mmalloc readline glob
1086 GDB_SUPPORT_FILES
= $(GDB_SUPPORT_DIRS
) texinfo
/fsf
/texinfo.
tex
1088 setup-dirs
: force_update
1091 .
/configure
-rm sun4
1092 chmod og
=u
`find $(DEVO_SUPPORT) $(GDB_SUPPORT_FILES) -print`
1094 bfd.ilrt.
tar.Z
: setup-dirs
1095 rm -f bfd.ilrt.
tar.Z
1096 tar cf
- $(DEVO_SUPPORT
) $(GDB_SUPPORT_FILES
) \
1097 | compress
-v
>bfd.ilrt.
tar.Z
1099 gdb.
tar.Z
: setup-dirs
1100 (cd gdb
; $(MAKE
) -f Makefile.in make-proto-gdb.
dir)
1101 $(MAKE
) $(MFLAGS
) -f Makefile.in make-gdb.
tar.Z
1103 make-gdb.
tar.Z
: $(DEVO_SUPPORT
) $(GDB_SUPPORT_DIRS
) gdb texinfo
/fsf
/texinfo.
tex
1104 rm -rf proto-toplev
; mkdir proto-toplev
1105 ln
-s ..
/gdb
/proto-gdb.
dir proto-toplev
/gdb
1106 (cd proto-toplev
; for i in
$(DEVO_SUPPORT
) $(GDB_SUPPORT_DIRS
); do \
1109 # Put only one copy (four hard links) of COPYING in the tar file.
1110 rm proto-toplev
/bfd
/COPYING
1111 ln proto-toplev
/gdb
/COPYING proto-toplev
/bfd
/COPYING
1112 rm proto-toplev
/include/COPYING
1113 ln proto-toplev
/gdb
/COPYING proto-toplev
/include/COPYING
1114 rm proto-toplev
/readline
/COPYING
1115 ln proto-toplev
/gdb
/COPYING proto-toplev
/readline
/COPYING
1116 # Take out texinfo from configurable dirs
1117 rm proto-toplev
/configure.in
1118 sed
'/^configdirs=/s/texinfo //' <configure.in
>proto-toplev
/configure.in
1119 # Take out glob from buildable dirs
1120 rm proto-toplev
/Makefile.in
1121 sed
'/^SUBDIRS =/s/glob //' <Makefile.in
>proto-toplev
/Makefile.in
1122 # Take out texinfo from buildable dirs
1123 cp proto-toplev
/Makefile.in temp.
$$
1124 sed
'/^all\.normal: /s/\all-texinfo //' <temp.
$$ >temp1.
$$
1125 sed
'/^clean: /s/clean-texinfo //' <temp1.
$$ >temp.
$$
1126 sed
'/^install\.all: /s/install-texinfo //' <temp.
$$ >proto-toplev
/Makefile.in
1128 mkdir proto-toplev
/texinfo
1129 mkdir proto-toplev
/texinfo
/fsf
1130 ln
-s ..
/..
/..
/texinfo
/fsf
/texinfo.
tex proto-toplev
/texinfo
/fsf
/
1131 chmod og
=u
`find proto-toplev -print`
1132 (VER
=`sed <gdb/Makefile.in -n 's/VERSION = //p'`; \
1133 echo
"==> Making gdb-$$VER.tar.Z"; \
1134 ln
-s proto-toplev gdb-
$$VER; \
1135 tar cfh
- gdb-
$$VER \
1136 | compress
-v
>gdb-
$$VER.
tar.Z
)
1142 # end of Makefile.in