Fri Jan 15 10:27:02 1993 Ian Lance Taylor (ian@cygnus.com)
[deliverable/binutils-gdb.git] / Makefile.in
1 #
2 # Makefile for directory with subdirs to build.
3 # Copyright (C) 1990, 1991, 1992 Free Software Foundation
4 #
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.
9 #
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.
14 #
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. */
18 #
19
20 srcdir = .
21
22 prefix = /usr/local
23
24 exec_prefix = $(prefix)
25 bindir = $(exec_prefix)/bin
26 libdir = $(exec_prefix)/lib
27 tooldir = $(libdir)
28
29 program_transform_name =
30
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
45
46 SHELL = /bin/sh
47
48 INSTALL = cp
49 INSTALL_PROGRAM = $(INSTALL)
50 INSTALL_DATA = $(INSTALL)
51
52 AS = as
53 AR = ar
54 AR_FLAGS = rc
55 CC = cc
56 CFLAGS = -g
57 CXX = gcc
58 CXXFLAGS = -g -O
59 GCC_FOR_TARGET = ./xgcc -B./
60 RANLIB = ranlib
61 NM = nm
62
63 BISON = `if [ -f $${rootme}/byacc/byacc ] ; \
64 then echo $${rootme}/byacc/byacc ; \
65 else echo byacc ; \
66 fi`
67
68 LEX = `if [ -f $${rootme}/flex/flex ] ; \
69 then echo $${rootme}/flex/flex ; \
70 else echo flex ; fi`
71
72 MAKEINFO = `if [ -f $${rootme}/texinfo/C/makeinfo ] ; \
73 then echo $${rootme}/texinfo/C/makeinfo ; \
74 else echo makeinfo ; fi`
75
76 # compilers to use to create programs which must be run in the build
77 # environment.
78 CC_FOR_BUILD = $(CC)
79 CXX_FOR_BUILD = $(CXX)
80
81 SUBDIRS = "this is set via configure, don't edit this"
82 OTHERS =
83
84 ALL = all.normal
85 INSTALL_TARGET = install.all
86
87 ### for debugging
88 #GCCVERBOSE=-v
89
90 CC_FOR_TARGET = ` \
91 if [ -f $${rootme}/gcc/Makefile ] ; then \
92 echo $${rootme}/gcc/xgcc -B$${rootme}/gcc/; \
93 else \
94 if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
95 echo $(CC); \
96 else \
97 t='$(program_transform_name)'; echo gcc | sed -e '' $$t; \
98 fi; \
99 fi`
100
101 CXX_FOR_TARGET = ` \
102 if [ -f $${rootme}/gcc/Makefile ] ; then \
103 echo $${rootme}/gcc/xgcc -B$${rootme}/gcc/; \
104 else \
105 if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
106 echo $(CXX); \
107 else \
108 t='$(program_transform_name)'; echo gcc | sed -e '' $$t; \
109 fi; \
110 fi`
111
112 AS_FOR_TARGET = ` \
113 if [ -f $${rootme}/gas/Makefile ] ; then \
114 echo $${rootme}/gas/as.new ; \
115 else \
116 if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
117 echo $(AS); \
118 else \
119 t='$(program_transform_name)'; echo as | sed -e '' $$t ; \
120 fi \
121 fi`
122
123 AR_FOR_TARGET = ` \
124 if [ -f $${rootme}/binutils/Makefile ] ; then \
125 echo $${rootme}/binutils/ar ; \
126 else \
127 if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
128 echo $(AR); \
129 else \
130 t='$(program_transform_name)'; echo ar | sed -e '' $$t ; \
131 fi \
132 fi`
133
134 RANLIB_FOR_TARGET = ` \
135 if [ -f $${rootme}/binutils/Makefile ] ; then \
136 echo $${rootme}/binutils/ranlib ; \
137 else \
138 if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
139 echo $(RANLIB); \
140 else \
141 t='$(program_transform_name)'; echo ranlib | sed -e '' $$t ; \
142 fi \
143 fi`
144
145 NM_FOR_TARGET = ` \
146 if [ -f $${rootme}/binutils/Makefile ] ; then \
147 echo $${rootme}/binutils/nm ; \
148 else \
149 if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
150 echo $(NM); \
151 else \
152 t='$(program_transform_name)'; echo nm | sed -e '' $$t ; \
153 fi \
154 fi`
155
156 XTRAFLAGS = ` \
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 ; \
160 else \
161 echo -I$${rootme}/gcc/include ; \
162 fi ; \
163 else \
164 echo ; \
165 fi`
166
167
168 #### host and target specific makefile fragments come in here.
169 ###
170
171 # Flags to pass down to sub-makes -- please keep these in alphabetical order
172 FLAGS_TO_PASS = \
173 "AR=$(AR)" \
174 "AR_FLAGS=$(AR_FLAGS)" \
175 "AR_FOR_TARGET=$(AR_FOR_TARGET)" \
176 "BISON=$(BISON)" \
177 "CXXFLAGS=$(CXXFLAGS)" \
178 "CXX_FOR_BUILD=$(CXX_FOR_BUILD)" \
179 "CC=$(CC)" \
180 "CC_FOR_BUILD=$(CC_FOR_BUILD)" \
181 "CFLAGS=$(CFLAGS)" \
182 "GCC_FOR_TARGET=$(GCC_FOR_TARGET)" \
183 "INSTALL=$(INSTALL)" \
184 "INSTALL_DATA=$(INSTALL_DATA)" \
185 "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \
186 "LDFLAGS=$(LDFLAGS)" \
187 "LEX=$(LEX)" \
188 "LOADLIBES=$(LOADLIBES)" \
189 "MAKEINFO=$(MAKEINFO)" \
190 "RANLIB=$(RANLIB)" \
191 "RANLIB_FOR_TARGET=$(RANLIB_FOR_TARGET)" \
192 "exec_prefix=$(exec_prefix)" \
193 "prefix=$(prefix)" \
194 "tooldir=$(tooldir)"
195
196 # Flags that are concerned with the location of the X11 include files
197 # and library files
198 X11_FLAGS_TO_PASS = \
199 "X11_INCLUDE_FLAGS=$(X11_INCLUDE_FLAGS)" \
200 "X11_LIB_FLAGS=$(X11_LIB_FLAGS)"
201
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)" \
208 "BISON=$(BISON)" \
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)" \
214 "CFLAGS=$(CFLAGS)" \
215 "INSTALL=$(INSTALL)" \
216 "INSTALL_DATA=$(INSTALL_DATA)" \
217 "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \
218 "LDFLAGS=$(LDFLAGS)" \
219 "LEX=$(LEX)" \
220 "LOADLIBES=$(LOADLIBES)" \
221 "MAKEINFO=$(MAKEINFO)" \
222 "NM=$(NM_FOR_TARGET)" \
223 "RANLIB=$(RANLIB_FOR_TARGET)" \
224 "XTRAFLAGS=$(XTRAFLAGS)" \
225 "exec_prefix=$(exec_prefix)" \
226 "prefix=$(prefix)" \
227 "tooldir=$(tooldir)"
228
229 # Flags to pass down to gcc. gcc builds a library, libgcc.a, so it
230 # unfortunately needs the native compiler and the target ar and
231 # ranlib. Keep these in alphabetical order, please.
232 GCC_FLAGS_TO_PASS = \
233 "AR=$(AR_FOR_TARGET)" \
234 "AR_FLAGS=$(AR_FLAGS)" \
235 "AR_FOR_TARGET=$(AR_FOR_TARGET)" \
236 "AS=$(AS)" \
237 "BISON=$(BISON)" \
238 "CXX=$(CXX)" \
239 "CXX_FOR_BUILD=$(CXX_FOR_BUILD)" \
240 "CXXFLAGS=$(CXXFLAGS)" \
241 "CC=$(CC)" \
242 "CC_FOR_BUILD=$(CC_FOR_BUILD)" \
243 "CFLAGS=$(CFLAGS)" \
244 "INSTALL=$(INSTALL)" \
245 "INSTALL_DATA=$(INSTALL_DATA)" \
246 "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \
247 "LDFLAGS=$(LDFLAGS)" \
248 "LEX=$(LEX)" \
249 "LOADLIBES=$(LOADLIBES)" \
250 "MAKEINFO=$(MAKEINFO)" \
251 "NM=$(NM)" \
252 "RANLIB=$(RANLIB_FOR_TARGET)" \
253 "RANLIB_FOR_TARGET=$(RANLIB_FOR_TARGET)" \
254 "XTRAFLAGS=$(XTRAFLAGS)" \
255 "exec_prefix=$(exec_prefix)" \
256 "prefix=$(prefix)" \
257 "tooldir=$(tooldir)"
258
259 # The first rule in the file had better be this one. Don't put any above it.
260 all: $(ALL)
261
262 .PHONY: all check dvi info install-info
263 .NOEXPORT:
264
265 info check dvi:
266 @rootme=`pwd` ; export rootme ; \
267 $(MAKE) $(FLAGS_TO_PASS) DO=$@ "DODIRS=$(SUBDIRS)" subdir_do
268
269 install-info: install-info-dirs force
270 -parent=`echo $(infodir)|sed -e 's@/[^/]*$$@@'`; \
271 if [ -d $$parent ] ; then true ; else mkdir $$parent ; fi
272 -if [ -d $(infodir) ] ; then true ; else mkdir $(infodir) ; fi
273 @rootme='pwd' ; export rootme ; $(MAKE) $(FLAGS_TO_PASS) DO=install-info "DODIRS=$(SUBDIRS)" subdir_do
274 @rootme='pwd' ; export rootme ; $(MAKE) $(FLAGS_TO_PASS) dir.info install-dir.info
275
276 install-dir.info:
277 -parent=`echo $(infodir)|sed -e 's@/[^/]*$$@@'`; \
278 if [ -d $$parent ] ; then true ; else mkdir $$parent ; fi
279 -if [ -d $(infodir) ] ; then true ; else mkdir $(infodir) ; fi
280 $(INSTALL_DATA) dir.info $(infodir)/dir.info
281
282 all.normal: all-m4 all-autoconf all-libiberty all-mmalloc all-texinfo \
283 all-byacc all-flex all-opcodes all-bfd all-ld all-gas all-tgas \
284 all-gcc all-binutils all-libg++ all-readline all-z8ksim all-h8300sim all-gdb \
285 all-make all-rcs all-cvs all-diff all-grep \
286 all-patch all-emacs all-ispell all-etc \
287 all-tcl all-tk all-expect \
288 all-newlib \
289 $(start-sanitize-chill) \
290 all-chillrt \
291 $(end-sanitize-chill) \
292 all-gprof all-send_pr all-libm all-deja-gnu \
293 all-fileutils all-find all-gawk all-sed all-shellutils \
294 all-textutils all-time all-wdiff
295
296
297 all.cross: all-libiberty all-mmalloc all-gas all-byacc all-flex all-ld \
298 all-opcodes all-z8ksim all-h8300sim all-bfd all-readline \
299 all-gdb all-binutils all-gcc all-newlib \
300 $(start-sanitize-chill) \
301 all-chillrt \
302 $(end-sanitize-chill) \
303 all-deja-gnu
304
305 .PHONY: clean distclean mostlyclean realclean do_clean
306
307 do_clean:
308 -rm -f *.a TEMP errs core *.o *~ \#* TAGS *.E
309
310 clean mostlyclean: do_clean
311 @rootme=`pwd` ; export rootme ; \
312 $(MAKE) $(FLAGS_TO_PASS) DO=$@ "DODIRS=$(SUBDIRS)" subdir_do
313
314 distclean realclean: do_clean
315 @rootme=`pwd` ; export rootme ; \
316 $(MAKE) $(FLAGS_TO_PASS) DO=$@ "DODIRS=$(SUBDIRS)" subdir_do
317 -rm -f Makefile config.status
318
319 uninstall:
320 @echo "the uninstall target is not supported in this tree"
321
322 install: $(INSTALL_TARGET)
323 -parent=`echo $(man1dir)|sed -e 's@/[^/]*$$@@'`; \
324 if [ -d $$parent ] ; then true ; else mkdir $$parent ; fi
325 -if [ -d $(man1dir) ] ; then true ; else mkdir $(man1dir) ; fi
326
327 install.all: install-no-fixedincludes
328 @if [ -f ./gcc/Makefile ] ; then \
329 rootme=`pwd` ; export rootme ; \
330 (cd ./gcc; \
331 $(MAKE) $(FLAGS_TO_PASS) install-headers) ; \
332 else \
333 true ; \
334 fi
335
336 install-no-fixedincludes: install-dirs gcc-no-fixedincludes \
337 install-autoconf \
338 install-bfd \
339 install-binutils \
340 install-opcodes \
341 install-byacc \
342 install-cvs \
343 install-diff \
344 install-deja-gnu \
345 install-emacs \
346 install-etc \
347 install-expect \
348 install-flex \
349 install-gas \
350 install-gdb \
351 install-glob \
352 install-gprof \
353 install-grep \
354 install-ispell \
355 install-ld \
356 install-libg++ \
357 install-libiberty \
358 install-libm \
359 install-make \
360 install-mmalloc \
361 install-newlib \
362 $(start-sanitize-chill) \
363 install-chillrt \
364 $(end-sanitize-chill) \
365 install-patch \
366 install-rcs \
367 install-readline \
368 install-send_pr \
369 install-tcl \
370 install-texinfo \
371 install-tk \
372 install-z8ksim \
373 install-h8300sim \
374 install-fileutils install-find install-gawk install-m4 install-sed install-shellutils \
375 install-textutils install-time install-wdiff
376
377 gcc-no-fixedincludes:
378 @if [ -f ./gcc/Makefile ] ; then \
379 rootme=`pwd` ; export rootme ; \
380 (cd ./gcc; \
381 $(MAKE) $(FLAGS_TO_PASS) install install-man \
382 "INSTALL_HEADERS=install-common-headers install-float-h install-limits-h") ; \
383 else \
384 true ; \
385 fi
386
387 install.cross: install-dirs install-libiberty install-mmalloc \
388 install-binutils install-opcodes install-byacc install-flex \
389 install-ld install-gas install-readline \
390 install-glob install-gdb install-mmalloc \
391 install-newlib \
392 $(start-sanitize-chill) \
393 install-chillrt \
394 $(end-sanitize-chill) \
395 install-gcc install-etc install-deja-gnu
396
397 ### deja-gnu
398 all-deja-gnu: force
399 @if [ -f ./deja-gnu/Makefile ] ; then \
400 rootme=`pwd` ; export rootme ; \
401 (cd ./deja-gnu; $(MAKE) $(FLAGS_TO_PASS) all) ; \
402 else \
403 true ; \
404 fi
405
406 install-deja-gnu: force
407 @if [ -f ./deja-gnu/Makefile ] ; then \
408 rootme=`pwd` ; export rootme ; \
409 (cd ./deja-gnu; $(MAKE) $(FLAGS_TO_PASS) install) ; \
410 else \
411 true ; \
412 fi
413
414 ### autoconf
415 all-autoconf: force
416 @if [ -f ./autoconf/Makefile ] ; then \
417 rootme=`pwd` ; export rootme ; \
418 (cd ./autoconf; $(MAKE) $(FLAGS_TO_PASS) all) ; \
419 else \
420 true ; \
421 fi
422
423 install-autoconf: force
424 @if [ -f ./autoconf/Makefile ] ; then \
425 rootme=`pwd` ; export rootme ; \
426 (cd ./autoconf; $(MAKE) $(FLAGS_TO_PASS) install) ; \
427 else \
428 true ; \
429 fi
430
431 ### etc
432 all-etc: force
433 @if [ -f ./etc/Makefile ] ; then \
434 rootme=`pwd` ; export rootme ; \
435 (cd ./etc; $(MAKE) $(FLAGS_TO_PASS) all) ; \
436 else \
437 true ; \
438 fi
439
440 install-etc: force
441 @if [ -f ./etc/Makefile ] ; then \
442 rootme=`pwd` ; export rootme ; \
443 (cd ./etc; $(MAKE) $(FLAGS_TO_PASS) install) ; \
444 else \
445 true ; \
446 fi
447
448 ### libiberty
449 all-libiberty: force
450 @if [ -f ./libiberty/Makefile ] ; then \
451 rootme=`pwd` ; export rootme ; \
452 (cd ./libiberty; \
453 $(MAKE) $(FLAGS_TO_PASS) all) ; \
454 else \
455 true ; \
456 fi
457
458 install-libiberty: force
459 @if [ -f ./libiberty/Makefile ] ; then \
460 rootme=`pwd` ; export rootme ; \
461 (cd ./libiberty; \
462 $(MAKE) $(FLAGS_TO_PASS) install) ; \
463 else \
464 true ; \
465 fi
466
467 ### xiberty
468 all-xiberty: all-gcc all-newlib
469 @if [ -f ./xiberty/Makefile ] ; then \
470 rootme=`pwd` ; export rootme ; \
471 srcroot=`cd $(srcdir); pwd`; export srcroot ; \
472 (cd ./xiberty; \
473 $(MAKE) $(TARGET_FLAGS_TO_PASS) all) ; \
474 else \
475 true ; \
476 fi
477
478 install-xiberty: force
479 @if [ -f ./xiberty/Makefile ] ; then \
480 rootme=`pwd` ; export rootme ; \
481 srcroot=`cd $(srcdir); pwd`; export srcroot ; \
482 (cd ./xiberty; \
483 $(MAKE) $(TARGET_FLAGS_TO_PASS) install) ; \
484 else \
485 true ; \
486 fi
487
488 ### mmalloc
489 all-mmalloc: force
490 @if [ -f ./mmalloc/Makefile ] ; then \
491 rootme=`pwd` ; export rootme ; \
492 (cd ./mmalloc; \
493 $(MAKE) $(FLAGS_TO_PASS) all) ; \
494 else \
495 true ; \
496 fi
497
498 install-mmalloc: force
499 @if [ -f ./mmalloc/Makefile ] ; then \
500 rootme=`pwd` ; export rootme ; \
501 (cd ./mmalloc; \
502 $(MAKE) $(FLAGS_TO_PASS) install) ; \
503 else \
504 true ; \
505 fi
506
507 ### texinfo
508 all-texinfo: all-libiberty
509 @if [ -f ./texinfo/Makefile ] ; then \
510 rootme=`pwd` ; export rootme ; \
511 (cd ./texinfo; \
512 $(MAKE) $(FLAGS_TO_PASS) all) ; \
513 else \
514 true ; \
515 fi
516
517 install-texinfo: force
518 @if [ -f ./texinfo/Makefile ] ; then \
519 rootme=`pwd` ; export rootme ; \
520 (cd ./texinfo; \
521 $(MAKE) $(FLAGS_TO_PASS) install) ; \
522 else \
523 true ; \
524 fi
525
526 ### bfd
527 all-bfd: force
528 @if [ -f ./bfd/Makefile ] ; then \
529 rootme=`pwd` ; export rootme ; \
530 (cd ./bfd; \
531 $(MAKE) $(FLAGS_TO_PASS) all) ; \
532 else \
533 true ; \
534 fi
535
536 install-bfd: force
537 @if [ -f ./bfd/Makefile ] ; then \
538 rootme=`pwd` ; export rootme ; \
539 (cd ./bfd; \
540 $(MAKE) $(FLAGS_TO_PASS) install) ; \
541 else \
542 true ; \
543 fi
544
545
546 ### opcodes
547 all-opcodes: force
548 @if [ -f ./opcodes/Makefile ] ; then \
549 rootme=`pwd` ; export rootme ; \
550 (cd ./opcodes; \
551 $(MAKE) $(FLAGS_TO_PASS) all) ; \
552 else \
553 true ; \
554 fi
555
556 install-opcodes: force
557 @if [ -f ./opcodes/Makefile ] ; then \
558 rootme=`pwd` ; export rootme ; \
559 (cd ./opcodes; \
560 $(MAKE) $(FLAGS_TO_PASS) install) ; \
561 else \
562 true ; \
563 fi
564
565 ### binutils
566 all-binutils: all-opcodes all-libiberty all-bfd all-flex
567 @if [ -f ./binutils/Makefile ] ; then \
568 rootme=`pwd` ; export rootme ; \
569 (cd ./binutils; \
570 $(MAKE) $(FLAGS_TO_PASS) all) ; \
571 else \
572 true ; \
573 fi
574
575 install-binutils: force
576 @if [ -f ./binutils/Makefile ] ; then \
577 rootme=`pwd` ; export rootme ; \
578 (cd ./binutils; \
579 $(MAKE) $(FLAGS_TO_PASS) install) ; \
580 else \
581 true ; \
582 fi
583
584 ### newlib
585 all-newlib: all-binutils all-ld all-gas all-gcc
586 @if [ -f ./newlib/Makefile ] ; then \
587 rootme=`pwd` ; export rootme ; \
588 srcroot=`cd $(srcdir); pwd` ; export srcroot ; \
589 (cd ./newlib; \
590 $(MAKE) $(TARGET_FLAGS_TO_PASS) all) ; \
591 else \
592 true ; \
593 fi
594
595 install-newlib: force
596 @if [ -f ./newlib/Makefile ] ; then \
597 rootme=`pwd` ; export rootme ; \
598 srcroot=`cd $(srcdir); pwd` ; export srcroot ; \
599 (cd ./newlib; \
600 $(MAKE) $(TARGET_FLAGS_TO_PASS) install) ; \
601 else \
602 true ; \
603 fi
604
605 ### start-sanitize-chill
606 ### chillrt
607 all-chillrt: all-binutils all-ld all-gas all-gcc all-newlib
608 @if [ -f ./chillrt/Makefile ] ; then \
609 rootme=`pwd` ; export rootme ; \
610 srcroot=`cd $(srcdir); pwd` ; export srcroot ; \
611 (cd ./chillrt; \
612 $(MAKE) $(TARGET_FLAGS_TO_PASS) all) ; \
613 else \
614 true ; \
615 fi
616
617 install-chillrt: force
618 @if [ -f ./chillrt/Makefile ] ; then \
619 rootme=`pwd` ; export rootme ; \
620 srcroot=`cd $(srcdir); pwd` ; export srcroot ; \
621 (cd ./chillrt; \
622 $(MAKE) $(TARGET_FLAGS_TO_PASS) install) ; \
623 else \
624 true ; \
625 fi
626 ### end-sanitize-chill
627
628 ### gprof
629 all-gprof: all-libiberty all-bfd
630 @if [ -f ./gprof/Makefile ] ; then \
631 rootme=`pwd` ; export rootme ; \
632 (cd ./gprof; \
633 $(MAKE) $(FLAGS_TO_PASS) all) ; \
634 else \
635 true ; \
636 fi
637
638 install-gprof: force
639 @if [ -f ./gprof/Makefile ] ; then \
640 rootme=`pwd` ; export rootme ; \
641 (cd ./gprof; \
642 $(MAKE) $(FLAGS_TO_PASS) install) ; \
643 else \
644 true ; \
645 fi
646
647 ### byacc
648 all-byacc: force
649 @if [ -f ./byacc/Makefile ] ; then \
650 rootme=`pwd` ; export rootme ; \
651 (cd ./byacc; \
652 $(MAKE) $(FLAGS_TO_PASS) all) ; \
653 else \
654 true ; \
655 fi
656
657 install-byacc: force
658 @if [ -f ./byacc/Makefile ] ; then \
659 rootme=`pwd` ; export rootme ; \
660 (cd ./byacc; \
661 $(MAKE) $(FLAGS_TO_PASS) install) ; \
662 else \
663 true ; \
664 fi
665
666 ### flex
667 all-flex: all-libiberty
668 @if [ -f ./flex/Makefile ] ; then \
669 rootme=`pwd` ; export rootme ; \
670 (cd ./flex; \
671 $(MAKE) $(FLAGS_TO_PASS) all) ; \
672 else \
673 true ; \
674 fi
675
676 install-flex: force
677 @if [ -f ./flex/Makefile ] ; then \
678 rootme=`pwd` ; export rootme ; \
679 (cd ./flex; \
680 $(MAKE) $(FLAGS_TO_PASS) install) ; \
681 else \
682 true ; \
683 fi
684 ### gcc
685 all-gcc: all-libiberty all-byacc all-binutils
686 @if [ -f ./gcc/Makefile ] ; then \
687 rootme=`pwd` ; export rootme ; \
688 srcroot=`cd $(srcdir); pwd` ; export srcroot ; \
689 (cd ./gcc; \
690 $(MAKE) $(GCC_FLAGS_TO_PASS) all) ; \
691 else \
692 true ; \
693 fi
694
695 install-gcc: force
696 @if [ -f ./gcc/Makefile ] ; then \
697 rootme=`pwd` ; export rootme ; \
698 srcroot=`cd $(srcdir); pwd` ; export srcroot ; \
699 (cd ./gcc; \
700 $(MAKE) $(GCC_FLAGS_TO_PASS) install) ; \
701 else \
702 true ; \
703 fi
704
705 ### readline
706 all-readline: force
707 @if [ -f ./readline/Makefile ] ; then \
708 rootme=`pwd` ; export rootme ; \
709 (cd ./readline; \
710 $(MAKE) $(FLAGS_TO_PASS) all) ; \
711 else \
712 true ; \
713 fi
714
715 install-readline: force
716 @if [ -f ./readline/Makefile ] ; then \
717 rootme=`pwd` ; export rootme ; \
718 (cd ./readline; \
719 $(MAKE) $(FLAGS_TO_PASS) install) ; \
720 else \
721 true ; \
722 fi
723
724 ### glob
725 all-glob: force
726 @if [ -f ./glob/Makefile ] ; then \
727 rootme=`pwd` ; export rootme ; \
728 (cd ./glob; \
729 $(MAKE) $(FLAGS_TO_PASS) all) ; \
730 else \
731 true ; \
732 fi
733
734 install-glob: force
735 @if [ -f ./glob/Makefile ] ; then \
736 rootme=`pwd` ; export rootme ; \
737 (cd ./glob; \
738 $(MAKE) $(FLAGS_TO_PASS) install) ; \
739 else \
740 true ; \
741 fi
742
743 ### gas
744 all-gas: all-libiberty all-opcodes all-bfd
745 @if [ -f ./gas/Makefile ] ; then \
746 rootme=`pwd` ; export rootme ; \
747 (cd ./gas; \
748 $(MAKE) $(FLAGS_TO_PASS) all) ; \
749 else \
750 true ; \
751 fi
752
753 install-gas: force
754 @if [ -f ./gas/Makefile ] ; then \
755 rootme=`pwd` ; export rootme ; \
756 (cd ./gas; \
757 $(MAKE) $(FLAGS_TO_PASS) install) ; \
758 else \
759 true ; \
760 fi
761
762 ### gas
763 all-tgas: all-libiberty all-bfd
764 @if [ -f ./tgas/Makefile ] ; then \
765 rootme=`pwd` ; export rootme ; \
766 (cd ./tgas; \
767 $(MAKE) $(FLAGS_TO_PASS) all) ; \
768 else \
769 true ; \
770 fi
771
772
773 ### ld
774 all-ld: all-libiberty all-bfd all-byacc all-flex
775 @if [ -f ./ld/Makefile ] ; then \
776 rootme=`pwd` ; export rootme ; \
777 (cd ./ld; \
778 $(MAKE) $(FLAGS_TO_PASS) all) ; \
779 else \
780 true ; \
781 fi
782
783 install-ld: force
784 @if [ -f ./ld/Makefile ] ; then \
785 rootme=`pwd` ; export rootme ; \
786 (cd ./ld; \
787 $(MAKE) $(FLAGS_TO_PASS) install) ; \
788 else \
789 true ; \
790 fi
791
792 ### gdb
793 all-gdb: all-bfd all-opcodes all-libiberty all-mmalloc all-readline all-glob all-byacc
794 @if [ -f ./gdb/Makefile ] ; then \
795 rootme=`pwd` ; export rootme ; \
796 (cd ./gdb; \
797 $(MAKE) $(FLAGS_TO_PASS) all) ; \
798 else \
799 true ; \
800 fi
801
802 install-gdb: force
803 @if [ -f ./gdb/Makefile ] ; then \
804 rootme=`pwd` ; export rootme ; \
805 (cd ./gdb; \
806 $(MAKE) $(FLAGS_TO_PASS) install) ; \
807 else \
808 true ; \
809 fi
810
811 ### make
812 all-make: all-libiberty
813 @if [ -f ./make/Makefile ] ; then \
814 rootme=`pwd` ; export rootme ; \
815 (cd ./make; \
816 $(MAKE) $(FLAGS_TO_PASS) all) ; \
817 else \
818 true ; \
819 fi
820
821 install-make: force
822 @if [ -f ./make/Makefile ] ; then \
823 rootme=`pwd` ; export rootme ; \
824 (cd ./make; \
825 $(MAKE) $(FLAGS_TO_PASS) install) ; \
826 else \
827 true ; \
828 fi
829
830 ### diff
831 all-diff: force
832 @if [ -f ./diff/Makefile ] ; then \
833 rootme=`pwd` ; export rootme ; \
834 (cd ./diff; \
835 $(MAKE) $(FLAGS_TO_PASS) all) ; \
836 else \
837 true ; \
838 fi
839
840 install-diff: force
841 @if [ -f ./diff/Makefile ] ; then \
842 rootme=`pwd` ; export rootme ; \
843 (cd ./diff/; \
844 $(MAKE) $(FLAGS_TO_PASS) install) ; \
845 else \
846 true ; \
847 fi
848
849 ### grep
850 all-grep: force
851 @if [ -f ./grep/Makefile ] ; then \
852 rootme=`pwd` ; export rootme ; \
853 (cd ./grep; \
854 $(MAKE) $(FLAGS_TO_PASS) all) ; \
855 else \
856 true ; \
857 fi
858
859 install-grep: force
860 @if [ -f ./grep/Makefile ] ; then \
861 rootme=`pwd` ; export rootme ; \
862 (cd ./grep; \
863 $(MAKE) $(FLAGS_TO_PASS) install) ; \
864 else \
865 true ; \
866 fi
867
868 ### rcs
869 all-rcs: force
870 @if [ -f ./rcs/Makefile ] ; then \
871 rootme=`pwd` ; export rootme ; \
872 (cd ./rcs; \
873 $(MAKE) $(FLAGS_TO_PASS) all) ; \
874 else \
875 true ; \
876 fi
877
878 install-rcs: force
879 @if [ -f ./rcs/Makefile ] ; then \
880 rootme=`pwd` ; export rootme ; \
881 (cd ./rcs; \
882 $(MAKE) $(FLAGS_TO_PASS) install) ; \
883 else \
884 true ; \
885 fi
886
887 ### cvs
888 all-cvs: force
889 @if [ -f ./cvs/Makefile ] ; then \
890 rootme=`pwd` ; export rootme ; \
891 (cd ./cvs; \
892 $(MAKE) $(FLAGS_TO_PASS) all) ; \
893 else \
894 true ; \
895 fi
896
897 install-cvs: force
898 @if [ -f ./cvs/Makefile ] ; then \
899 rootme=`pwd` ; export rootme ; \
900 (cd ./cvs; \
901 $(MAKE) $(FLAGS_TO_PASS) install) ; \
902 else \
903 true ; \
904 fi
905
906 ### patch
907 all-patch: force
908 @if [ -f ./patch/Makefile ] ; then \
909 rootme=`pwd` ; export rootme ; \
910 (cd ./patch; \
911 $(MAKE) $(FLAGS_TO_PASS) all) ; \
912 else \
913 true ; \
914 fi
915
916 install-patch: force
917 @if [ -f ./patch/Makefile ] ; then \
918 rootme=`pwd` ; export rootme ; \
919 (cd ./patch; \
920 $(MAKE) $(FLAGS_TO_PASS) \
921 bindir=$(bindir) \
922 man1dir=$(man1dir) install) ; \
923 else \
924 true ; \
925 fi
926
927 ### emacs
928 all-emacs: force
929 @if [ -f ./emacs/Makefile ] ; then \
930 rootme=`pwd` ; export rootme ; \
931 (cd ./emacs; \
932 $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) all) ; \
933 else \
934 true ; \
935 fi
936
937 install-emacs: force
938 @if [ -f ./emacs/Makefile ] ; then \
939 rootme=`pwd` ; export rootme ; \
940 (cd ./emacs; \
941 $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) install) ; \
942 else \
943 true ; \
944 fi
945
946 ### ispell
947 all-ispell: all-emacs
948 @if [ -f ./ispell/Makefile ] ; then \
949 rootme=`pwd` ; export rootme ; \
950 (cd ./ispell; \
951 $(MAKE) $(FLAGS_TO_PASS) all) ; \
952 else \
953 true ; \
954 fi
955
956 install-ispell: force
957 @if [ -f ./ispell/Makefile ] ; then \
958 rootme=`pwd` ; export rootme ; \
959 (cd ./ispell; \
960 $(MAKE) $(FLAGS_TO_PASS) install) ; \
961 else \
962 true ; \
963 fi
964
965 ### send_pr
966 all-send_pr: force
967 @if [ -f ./send_pr/Makefile ] ; then \
968 rootme=`pwd` ; export rootme ; \
969 (cd ./send_pr; \
970 $(MAKE) $(FLAGS_TO_PASS) all) ; \
971 else \
972 true ; \
973 fi
974
975 install-send_pr: force
976 @if [ -f ./send_pr/Makefile ] ; then \
977 rootme=`pwd` ; export rootme ; \
978 (cd ./send_pr; \
979 $(MAKE) $(FLAGS_TO_PASS) install) ; \
980 else \
981 true ; \
982 fi
983
984 ### libm
985 all-libm: force
986 @if [ -f ./libm/Makefile ] ; then \
987 rootme=`pwd` ; export rootme ; \
988 (cd ./libm; \
989 $(MAKE) $(TARGET_FLAGS_TO_PASS) all) ; \
990 else \
991 true ; \
992 fi
993
994 install-libm: force
995 @if [ -f ./libm/Makefile ] ; then \
996 rootme=`pwd` ; export rootme ; \
997 (cd ./libm; \
998 $(MAKE) $(TARGET_FLAGS_TO_PASS) install) ; \
999 else \
1000 true ; \
1001 fi
1002
1003 ### libg++
1004
1005 all-libg++: all-gas all-ld all-gcc all-xiberty all-newlib
1006 @if [ -f ./libg++/Makefile ] ; then \
1007 rootme=`pwd` ; export rootme ; \
1008 srcroot=`cd $(srcdir); pwd` ; export srcroot ; \
1009 (cd ./libg++; \
1010 $(MAKE) $(TARGET_FLAGS_TO_PASS) all) ; \
1011 else \
1012 true ; \
1013 fi
1014
1015 install-libg++: force
1016 @if [ -f ./libg++/Makefile ] ; then \
1017 rootme=`pwd` ; export rootme ; \
1018 srcroot=`cd $(srcdir); pwd` ; export srcroot ; \
1019 (cd ./libg++; \
1020 $(MAKE) $(TARGET_FLAGS_TO_PASS) install) ; \
1021 else \
1022 true ; \
1023 fi
1024 ### tcl
1025 all-tcl:
1026 @if [ -f ./tcl/Makefile ] ; then \
1027 rootme=`pwd` ; export rootme ; \
1028 srcroot=`cd $(srcdir); pwd`; export srcroot ; \
1029 (cd ./tcl; \
1030 $(MAKE) $(FLAGS_TO_PASS) all) ; \
1031 else \
1032 true ; \
1033 fi
1034
1035 install-tcl: force
1036 @if [ -f ./tcl/Makefile ] ; then \
1037 rootme=`pwd` ; export rootme ; \
1038 srcroot=`cd $(srcdir); pwd`; export srcroot ; \
1039 (cd ./tcl; \
1040 $(MAKE) $(FLAGS_TO_PASS) install) ; \
1041 else \
1042 true ; \
1043 fi
1044
1045
1046 ### tk
1047 all-tk: all-tcl
1048 @if [ -f ./tk/Makefile ] ; then \
1049 rootme=`pwd` ; export rootme ; \
1050 srcroot=`cd $(srcdir); pwd`; export srcroot ; \
1051 (cd ./tk; \
1052 $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) all) ; \
1053 else \
1054 true ; \
1055 fi
1056
1057 install-tk: force
1058 @if [ -f ./tk/Makefile ] ; then \
1059 rootme=`pwd` ; export rootme ; \
1060 srcroot=`cd $(srcdir); pwd`; export srcroot ; \
1061 (cd ./tk; \
1062 $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) install) ; \
1063 else \
1064 true ; \
1065 fi
1066
1067 ### expect
1068 all-expect: all-tcl
1069 @if [ -f ./expect/Makefile ] ; then \
1070 rootme=`pwd` ; export rootme ; \
1071 srcroot=`cd $(srcdir); pwd`; export srcroot ; \
1072 (cd ./expect; \
1073 $(MAKE) $(FLAGS_TO_PASS) all) ; \
1074 else \
1075 true ; \
1076 fi
1077
1078 install-expect: force
1079 @if [ -f ./expect/Makefile ] ; then \
1080 rootme=`pwd` ; export rootme ; \
1081 srcroot=`cd $(srcdir); pwd`; export srcroot ; \
1082 (cd ./expect; \
1083 $(MAKE) $(FLAGS_TO_PASS) install) ; \
1084 else \
1085 true ; \
1086 fi
1087
1088 ### z8ksim
1089 all-z8ksim: all-bfd
1090 @if [ -f ./z8ksim/Makefile ] ; then \
1091 rootme=`pwd` ; export rootme ; \
1092 (cd ./z8ksim; \
1093 $(MAKE) $(FLAGS_TO_PASS) all) ; \
1094 else \
1095 true ; \
1096 fi
1097
1098 install-z8ksim: force
1099 @if [ -f ./z8ksim/Makefile ] ; then \
1100 rootme=`pwd` ; export rootme ; \
1101 (cd ./z8ksim; \
1102 $(MAKE) $(FLAGS_TO_PASS) install) ; \
1103 else \
1104 true ; \
1105 fi
1106
1107 ### h8300sim:
1108 all-h8300sim: all-bfd
1109 @if [ -f ./h8300sim/Makefile ] ; then \
1110 rootme=`pwd` ; export rootme ; \
1111 (cd ./h8300sim; \
1112 $(MAKE) $(FLAGS_TO_PASS) all) ; \
1113 else \
1114 true ; \
1115 fi
1116
1117 install-h8300sim: force
1118 @if [ -f ./h8300sim/Makefile ] ; then \
1119 rootme=`pwd` ; export rootme ; \
1120 (cd ./h8300sim; \
1121 $(MAKE) $(FLAGS_TO_PASS) install) ; \
1122 else \
1123 true ; \
1124 fi
1125
1126
1127 ### fileutils
1128 all-fileutils: force
1129 @if [ -f ./fileutils/Makefile ] ; then \
1130 rootme=`pwd` ; export rootme ; \
1131 (cd ./fileutils; $(MAKE) $(FLAGS_TO_PASS) all) ; \
1132 else \
1133 true ; \
1134 fi
1135
1136 install-fileutils: force
1137 @if [ -f ./fileutils/Makefile ] ; then \
1138 rootme=`pwd` ; export rootme ; \
1139 (cd ./fileutils; $(MAKE) $(FLAGS_TO_PASS) install) ; \
1140 else \
1141 true ; \
1142 fi
1143
1144 ### find
1145 all-find: force
1146 @if [ -f ./find/Makefile ] ; then \
1147 rootme=`pwd` ; export rootme ; \
1148 (cd ./find; $(MAKE) $(FLAGS_TO_PASS) all) ; \
1149 else \
1150 true ; \
1151 fi
1152
1153 install-find: force
1154 @if [ -f ./find/Makefile ] ; then \
1155 rootme=`pwd` ; export rootme ; \
1156 (cd ./find; $(MAKE) $(FLAGS_TO_PASS) install) ; \
1157 else \
1158 true ; \
1159 fi
1160
1161 ### gawk
1162 all-gawk: force
1163 @if [ -f ./gawk/Makefile ] ; then \
1164 rootme=`pwd` ; export rootme ; \
1165 (cd ./gawk; $(MAKE) $(FLAGS_TO_PASS) all) ; \
1166 else \
1167 true ; \
1168 fi
1169
1170 install-gawk: force
1171 @if [ -f ./gawk/Makefile ] ; then \
1172 rootme=`pwd` ; export rootme ; \
1173 (cd ./gawk; $(MAKE) $(FLAGS_TO_PASS) install) ; \
1174 else \
1175 true ; \
1176 fi
1177
1178 ### m4
1179 all-m4: all-libiberty
1180 @if [ -f ./m4/Makefile ] ; then \
1181 rootme=`pwd` ; export rootme ; \
1182 (cd ./m4; $(MAKE) $(FLAGS_TO_PASS) all) ; \
1183 else \
1184 true ; \
1185 fi
1186
1187 install-m4: force
1188 @if [ -f ./m4/Makefile ] ; then \
1189 rootme=`pwd` ; export rootme ; \
1190 (cd ./m4; $(MAKE) $(FLAGS_TO_PASS) install) ; \
1191 else \
1192 true ; \
1193 fi
1194
1195 ### sed
1196 all-sed: force
1197 @if [ -f ./sed/Makefile ] ; then \
1198 rootme=`pwd` ; export rootme ; \
1199 (cd ./sed; $(MAKE) $(FLAGS_TO_PASS) all) ; \
1200 else \
1201 true ; \
1202 fi
1203
1204 install-sed: force
1205 @if [ -f ./sed/Makefile ] ; then \
1206 rootme=`pwd` ; export rootme ; \
1207 (cd ./sed; $(MAKE) $(FLAGS_TO_PASS) install) ; \
1208 else \
1209 true ; \
1210 fi
1211
1212 ### time
1213 all-time: force
1214 @if [ -f ./time/Makefile ] ; then \
1215 rootme=`pwd` ; export rootme ; \
1216 (cd ./time; $(MAKE) $(FLAGS_TO_PASS) all) ; \
1217 else \
1218 true ; \
1219 fi
1220
1221 install-time: force
1222 @if [ -f ./time/Makefile ] ; then \
1223 rootme=`pwd` ; export rootme ; \
1224 (cd ./time; $(MAKE) $(FLAGS_TO_PASS) install) ; \
1225 else \
1226 true ; \
1227 fi
1228
1229 ### wdiff
1230 all-wdiff: force
1231 @if [ -f ./wdiff/Makefile ] ; then \
1232 rootme=`pwd` ; export rootme ; \
1233 (cd ./wdiff; $(MAKE) $(FLAGS_TO_PASS) all) ; \
1234 else \
1235 true ; \
1236 fi
1237
1238 install-wdiff: force
1239 @if [ -f ./wdiff/Makefile ] ; then \
1240 rootme=`pwd` ; export rootme ; \
1241 (cd ./wdiff; $(MAKE) $(FLAGS_TO_PASS) install) ; \
1242 else \
1243 true ; \
1244 fi
1245
1246 ### shellutils
1247 all-shellutils: force
1248 @if [ -f ./shellutils/Makefile ] ; then \
1249 rootme=`pwd` ; export rootme ; \
1250 (cd ./shellutils; $(MAKE) $(FLAGS_TO_PASS) all) ; \
1251 else \
1252 true ; \
1253 fi
1254
1255 install-shellutils: force
1256 @if [ -f ./shellutils/Makefile ] ; then \
1257 rootme=`pwd` ; export rootme ; \
1258 (cd ./shellutils; $(MAKE) $(FLAGS_TO_PASS) install) ; \
1259 else \
1260 true ; \
1261 fi
1262
1263 ### textutils
1264 all-textutils: force
1265 @if [ -f ./textutils/Makefile ] ; then \
1266 rootme=`pwd` ; export rootme ; \
1267 (cd ./textutils; $(MAKE) $(FLAGS_TO_PASS) all) ; \
1268 else \
1269 true ; \
1270 fi
1271
1272 install-textutils: force
1273 @if [ -f ./textutils/Makefile ] ; then \
1274 rootme=`pwd` ; export rootme ; \
1275 (cd ./textutils; $(MAKE) $(FLAGS_TO_PASS) install) ; \
1276 else \
1277 true ; \
1278 fi
1279
1280
1281
1282 ### other supporting targets
1283
1284 subdir_do:
1285 ### start-sanitize-chill
1286 ###
1287 ### WARNING: THIS IS VERY UGLY AND I DID NOT DO THIS WILLINGLY
1288 ###
1289 ### if you change the code for libg++ et al, also change the
1290 ### code for chillrt
1291 ###
1292 ### end-sanitize-chill
1293 @for i in $(DODIRS); do \
1294 if [ -f ./$$i/localenv ] || [ -f ./$$i/Makefile ] ; then \
1295 case $$i in \
1296 libg++ | xiberty | newlib) \
1297 if (rootme=`pwd` ; export rootme ; \
1298 srcroot=`cd $(srcdir); pwd` ; export srcroot ; \
1299 cd ./$$i ; \
1300 $(MAKE) $(TARGET_FLAGS_TO_PASS) $(DO)) ; then true ; \
1301 else exit 1 ; fi \
1302 ;; \
1303 $(start-sanitize-chill) \
1304 chillrt) \
1305 if (rootme=`pwd` ; export rootme ; \
1306 srcroot=`cd $(srcdir); pwd` ; export srcroot ; \
1307 cd ./$$i ; \
1308 $(MAKE) $(TARGET_FLAGS_TO_PASS) $(DO)) ; then true ; \
1309 else exit 1 ; fi \
1310 ;; \
1311 $(end-sanitize-chill) \
1312 gcc) \
1313 if (rootme=`pwd` ; export rootme ; \
1314 srcroot=`cd $(srcdir); pwd` ; export srcroot ; \
1315 cd ./$$i ; \
1316 $(MAKE) $(GCC_FLAGS_TO_PASS) $(DO)) ; then true ; \
1317 else exit 1 ; fi \
1318 ;; \
1319 *) \
1320 if (rootme=`pwd` ; export rootme ; \
1321 cd ./$$i ; \
1322 $(MAKE) $(FLAGS_TO_PASS) $(DO)) ; then true ; \
1323 else exit 1 ; fi \
1324 ;; \
1325 esac ; \
1326 else true ; fi ; \
1327 done
1328
1329 # The "else true" stuff is for Ultrix; the shell returns the exit code
1330 # of the "if" command, if no commands are run in the "then" or "else" part,
1331 # causing Make to quit.
1332
1333 MAKEDIRS= \
1334 $(prefix) \
1335 $(exec_prefix) \
1336 $(tooldir)
1337
1338 # $(bindir) \
1339 # $(libdir) \
1340 # $(includedir) \
1341 # $(datadir) \
1342 # $(docdir) \
1343 # $(mandir) \
1344 # $(man1dir) \
1345 # $(man5dir)
1346
1347 # $(man2dir) \
1348 # $(man3dir) \
1349 # $(man4dir) \
1350 # $(man6dir) \
1351 # $(man7dir) \
1352 # $(man8dir)
1353
1354 install-dirs:
1355 for i in $(MAKEDIRS) ; do \
1356 echo Making $$i... ; \
1357 parent=`echo $$i|sed -e 's@/[^/]*$$@@'`; \
1358 if [ -d $$parent ] ; then true ; else mkdir $$parent ; fi ; \
1359 if [ ! -d $$i ] ; then \
1360 if mkdir $$i ; then \
1361 true ; \
1362 else \
1363 exit 1 ; \
1364 fi ; \
1365 else \
1366 true ; \
1367 fi ; \
1368 done
1369
1370 install-info-dirs:
1371 if [ -d $(prefix) ] ; then true ; else mkdir $(prefix) ; fi
1372
1373 dir.info:
1374 $(srcdir)/texinfo/gen-info-dir $(infodir) $(srcdir)/texinfo/dir.info-template > dir.info.new
1375 mv -f dir.info.new dir.info
1376
1377 dist:
1378 @echo "Building a full distribution of this tree isn't done"
1379 @echo "via 'make dist'. Check out the etc/ subdirectory"
1380
1381 etags tags: TAGS
1382
1383 TAGS:
1384 etags `$(MAKE) ls`
1385
1386 ls:
1387 @echo Makefile
1388 @for i in $(SUBDIRS); \
1389 do \
1390 (cd $$i; \
1391 pwd=`pwd`; \
1392 wd=`basename $$pwd`; \
1393 for j in `$(MAKE) ls`; \
1394 do \
1395 echo $$wd/$$j; \
1396 done) \
1397 done
1398
1399 force:
1400
1401 # with the gnu make, this is done automatically.
1402
1403 Makefile: $(srcdir)/Makefile.in $(host_makefile_frag) $(target_makefile_frag)
1404 $(SHELL) ./config.status
1405
1406 #
1407 # Build GDB distributions that contain BFD, Include, Libiberty, Readline, etc
1408
1409 DEVO_SUPPORT= README cfg-paper.texi Makefile.in configure configure.in \
1410 config.sub config configure.man configure.texi move-if-change \
1411 COPYING.LIB
1412 GDB_SUPPORT_DIRS= bfd include libiberty mmalloc opcodes readline glob
1413 GDB_SUPPORT_FILES= $(GDB_SUPPORT_DIRS) texinfo/fsf/texinfo.tex
1414
1415 setup-dirs: force
1416 ./configure sun4
1417 make clean
1418 ./configure -rm sun4
1419 chmod og=u `find $(DEVO_SUPPORT) $(GDB_SUPPORT_FILES) -print`
1420
1421 gdb.tar.Z: setup-dirs
1422 (cd gdb; $(MAKE) -f Makefile.in make-proto-gdb.dir)
1423 $(MAKE) $(MFLAGS) -f Makefile.in make-gdb.tar.Z
1424
1425 make-gdb.tar.Z: $(DEVO_SUPPORT) $(GDB_SUPPORT_DIRS) gdb texinfo/fsf/texinfo.tex
1426 rm -rf proto-toplev; mkdir proto-toplev
1427 ln -s ../gdb/proto-gdb.dir proto-toplev/gdb
1428 (cd proto-toplev; for i in $(DEVO_SUPPORT) $(GDB_SUPPORT_DIRS); do \
1429 ln -s ../$$i . ; \
1430 done)
1431 # Put only one copy (four hard links) of COPYING in the tar file.
1432 rm proto-toplev/bfd/COPYING
1433 ln proto-toplev/gdb/COPYING proto-toplev/bfd/COPYING
1434 rm proto-toplev/include/COPYING
1435 ln proto-toplev/gdb/COPYING proto-toplev/include/COPYING
1436 rm proto-toplev/readline/COPYING
1437 ln proto-toplev/gdb/COPYING proto-toplev/readline/COPYING
1438 # Take out texinfo from configurable dirs
1439 rm proto-toplev/configure.in
1440 sed '/^configdirs=/s/texinfo //' <configure.in >proto-toplev/configure.in
1441 # Take out glob from buildable dirs
1442 rm proto-toplev/Makefile.in
1443
1444 sed -e '/^SUBDIRS =/s/glob //' \
1445 -e '/^all\.normal: /s/\all-texinfo //' \
1446 -e '/^clean: /s/clean-texinfo //' \
1447 -e '/^install\.all: /s/install-texinfo //' \
1448 <Makefile.in >proto-toplev/Makefile.in
1449
1450 mkdir proto-toplev/texinfo
1451 mkdir proto-toplev/texinfo/fsf
1452 ln -s ../../../texinfo/fsf/texinfo.tex proto-toplev/texinfo/fsf/
1453 chmod og=u `find proto-toplev -print`
1454 (VER=`sed <gdb/Makefile.in -n 's/VERSION = //p'`; \
1455 echo "==> Making gdb-$$VER.tar.Z"; \
1456 ln -s proto-toplev gdb-$$VER; \
1457 tar cfh - gdb-$$VER \
1458 | compress -v >gdb-$$VER.tar.Z)
1459
1460
1461 # end of Makefile.in
This page took 0.058922 seconds and 5 git commands to generate.